On 5/14/06, Fourat Zouari <[EMAIL PROTECTED]> wrote:

ok
this is returning the retrived data from open sockets :
http://pastebin.com/716768

this is returning an empty string :
http://pastebin.com/716767


it's not a bug :)
i shoul wait for stream to be returned, i use :
--------------------
       while(($buff = stream_get_contents($socket[$i]))=="");
       echo $buff;
--------------------
it takes sometime to receive stream from socket, is it the best way (dont
think so) to wait for stream ?


On 5/14/06, chris smith <[EMAIL PROTECTED]> wrote:
>
> On 5/14/06, Fourat Zouari <[EMAIL PROTECTED]> wrote:
> > Code 1 :
> > -------------------------
> > var_dump(stream_get_contents($rr));
> > -------------------------
> > Output 1
> > -------------------------
> > string(185) "HTTP/1.1 202 Accepted
> > Server: Apache2
> > Content-Length: 24
> > Connection: close
> > Content-type: text/html
> > Pragma: no-cache
> > Cache-Control: no-cache
> >
> > 0: Accepted for delivery"
> > -------------------------
> >
> >
> > Code 2 :
> > -------------------------
> > $x = stream_get_contents($rr);
> > var_dump($x);
> > -------------------------
> > Output 2
> > -------------------------
> > string(0) ""
> > -------------------------
> >
> > Am i wrong ?
>
> Without seeing all of the code, we can't tell anything from that.
>
> Post it in http://pastebin.com and send us a url.
>
> --
> Postgresql & php tutorials
> http://www.designmagick.com/
>


Reply via email to