Re: [PHP-DEV] is this fucntion still revavant??? From: Rasmus Lerdorf (rasmus <email protected>)
Date: 05/05/00

> function wc_conn ($host, $port, $files)
> {
> $functions = "GET"; /* Type of HTTP */
> $request = "$functions HTTP/1.0\n\n";

Don't you need $files in the above line?

> $fp = fsockopen($host,$port, &$errno, &$errstr, 30);
> fputs($fp, $request);
> $eof = feof($fp);
> $beyondheader = 0;
> while($beyondheader==0 && $eof==0) {
> $fromserver = fgets($fp, 1024);
> if (!ereg("^HTTP", $fromserver) && !ereg(".+: .+", $fromserver)) {
> $beyondheader=1;
> }
> $eof = feof($fp);
> }
>
> while($eof==0) {
> $fromserver = fgets($fp, 1024);
> $string += $fromserver;

That should be .=

Might work if you make those changes.

-Rasmus

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>