cURL / Mailing Lists / curl-users / Single Mail

curl-users

Re: Web service server doesn't see posted data

From: Dan Fandrich <dan_at_coneharvesters.com>
Date: Tue, 8 Apr 2008 15:55:24 -0700

On Tue, Apr 08, 2008 at 03:25:56PM -0700, Bruce, Henry wrote:
> However, when I tried the same approach with the NOAA weather service with the
> commands listed below, the call failed, with the server reporting it didn't see
> any parameters
>
> --url http://www.weather.gov/forecasts/xml/sample_products/browser_interface/
> ndfdXMLclient.php
> --data lat=45.550980
> --data lon=-122.917359
> --data product=time-series
> --data begin=2008-04-08T15:00:00
> --data end=2008-04-08T16:00:00
> --data pop12=pop12
>
> However, if I put the entire URI into the URL, it works just fine
> --url http://www.weather.gov/forecasts/xml/sample_products/browser_interface/
> ndfdXMLclient.php?&lat=45.550980&lon=-122.917359&product=time-series&begin=
> 2008-04-08T13:00:00&end=2008-04-08T14:00:00&pop12=pop12

The difference between the first and second commands is that the first does
a POST while the second does a GET. Add the -G option to the first one
and it should work.

>>> Dan

-- 
http://www.MoveAnnouncer.com              The web change of address service
          Let webmasters know that your web site has moved
Received on 2008-04-09