I have problem with the use of fgets() on a IIS 5 server with PHP 4.0 (It works fine on Apache). It will not accept the command $line = fgets($fp,1024); It just keeps running and times out at the end.
Does anyone know the reason for this. Does the fgets() works different on IIS?
It may be the result of not closing the connection, try this:
$var1 = fopen(file, "r"); while (!feof($var1)) { $var2 = fgets($var1, 4096); echo $var2; } fclose($var1); }
I remebered to close the connection. It must be something else because it works when I run it on Apache.