feof

From: Date: Mon, 17 May 1999 23:50:03 +0000
Subject: feof
Groups: php.dev 
Request: Send a blank email to php-dev+get-5750@lists.php.net to get a copy of this message
Hello all, running the short script $host = "funweb.de"; $port = 9000; $fp = fsockopen($host, $port); fputs($fp, "GET / HTTP/1.0\r\nHost: $host:$port\r\n\r\n"); while(trim(fgets($fp, 300)) != ""); while(!feof($fp)) echo fgets($fp, 256); echo "---\n"; while(($buf = fgets($fp, 256)) != false) echo $buf; yiels different output. PHP 3.0.[78] compiled as a shared module under Apache 1.3.6: --- <HTML><HEAD> <TITLE>404 File Not Found</TITLE> </HEAD><BODY> <H1>File Not Found</H1> The requested URL / was not found on this server.<P> </BODY></HTML> PHP 3.0.7 compiled as CGI/static module: <HTML><HEAD> <TITLE>404 File Not Found</TITLE> </HEAD><BODY> <H1>File Not Found</H1> The requested URL / was not found on this server.<P> </BODY></HTML> --- Notice the "---". Any ideas? -- Regards, Sascha Schumann Consultant -- PHP Development Mailing List http://www.php.net/ To unsubscribe send an empty message to php-dev-unsubscribe@lists.php.net For help: php-dev-help@lists.php.net

« previous php.dev (#5750) next »