[PD] send GET with netclient (pd <-> php)

IOhannes m zmoelnig zmoelnig at iem.at
Tue Sep 13 14:36:59 CEST 2005


Enrique Erne wrote:
> hi pd-list
> 
> I wondered if you've successfully sent a GET with netclient and  
> received something . I'd like to communicate with a php script this way  
> . Despite all my effort I never received any data from a server .
> 
> I tried Rune Lain Knudsen's WeatherTest1.pd :
> http://lists.puredata.info/pipermail/pd-list/2005-09/030918.html
> 
> connecting to port 80
> print: send GET  http://xoap.weather.com/search/local/NOXX0029? 
> cc=*prod=xoap&par=151y032476&key*
> netclient: connection closed on socket 9

hmm, i think that this is rather a problem with the protocol.
when i open a telnet session to xoap.weather.com and request the same 
GET, the server will close the connection too.

try sending something like:
"GET /search/local/NOXX0029 HTTP/1.0
"

(which gives me a redirect to another site)

> 
> or (endless output)
> 
> netclient: not connected
> netclient: not connected
> netclient: not connected
> netclient: not connected
> netclient: not connected
> netclient: not connected
> netclient: not connected
> (I don't know how this could happen but it wasn't the first time)

after the server closes the connection (and http-servers tend to close 
connections after each request), [netclient] is not connected any more - 
you have to reconnect.

mfg.ad.r
IOhannes




More information about the Pd-list mailing list