Lab # Exercise #17. Create a text file with multiple lines, and read those lines one line at a time.
**************************************************************
CODES:
<?php
$fileName = "lab02-14.txt";
$handle = fopen($fileName, "r") or die("Couldn't open $fileName");
if ($handle) {
while (!feof($handle)) {
$line = fgets($handle, 15); // the number here doesn't seem to matter. Is something wrong?
echo $line;
}
fclose($handle);
}
?>
**************************************************************
ANSWER:
This is a test
Here's another paragraph.