note 39169 added to function.fgets

From: Date: Mon, 19 Jan 2004 16:46:51 +0000
Subject: note 39169 added to function.fgets
Groups: php.notes 
Request: Send a blank email to php-notes+get-63836@lists.php.net to get a copy of this message
The Manual example prints a final empty line. I think a better example is: <?php $handle = fopen("/tmp/inputfile.txt", "r"); if ($handle) { $buffer = fgets($handle, 4096); while (!feof($handle)) { echo "$buffer"; $buffer = fgets($handle, 4096); } fclose($handle); } ?> ---- Manual Page -- http://www.php.net/manual/en/function.fgets.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+39169 Delete -- http://master.php.net/manage/user-notes.php?action=delete+39169&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+39169&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#63836) next »