php-4.0.3pl1: fgets and friends don't work
| From: | netbsd alpha | Date: | Wed, 25 Oct 2000 10:35:39 +0000 |
| Subject: | php-4.0.3pl1: fgets and friends don't work | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-21887@lists.php.net to get a copy of this message | ||
anyone having problems with fgets and friends? i have
scripts that have used those functions in the past and
have no problems. but after i upgraded to 4.0.3pl1, i
just get errors. here is a simple test script from
php's site:
---<cut>---
$fp = fsockopen ("www.php.net", 80, &$errno, &$errstr,
30);
if (!$fp) {
echo "$errstr ($errno)<br>\n";
} else {
fputs ($fp, "GET / HTTP/1.0\r\n\r\n");
while (!feof($fp)) {
echo fgets ($fp,128);
}
fclose ($fp);
}
---</cut>---
all i see is:
(0)
where as it should have returned the main php.net's page.
__________________________________________________
Do You Yahoo!?
Yahoo! Messenger - Talk while you surf! It's FREE.
http://im.yahoo.com/