Hello,
how can I read files into PHP. I can make a listing of a directory, but
reading the file content into the PHP goes wrong.
==== script ==========
<?php
$handle=opendir ('nieuws');
while (false!==($file = readdir($handle ))) {
if ($file != "." && $file != "..") {
$fp = fopen($file,"rb ");
fpassthru($fp);
fclose($fp);
echo $fp;
echo "<HR>";
}
}
closedir($handl e);
?>
===========
Thanx,
Marco J.L.
how can I read files into PHP. I can make a listing of a directory, but
reading the file content into the PHP goes wrong.
==== script ==========
<?php
$handle=opendir ('nieuws');
while (false!==($file = readdir($handle ))) {
if ($file != "." && $file != "..") {
$fp = fopen($file,"rb ");
fpassthru($fp);
fclose($fp);
echo $fp;
echo "<HR>";
}
}
closedir($handl e);
?>
===========
Thanx,
Marco J.L.
Comment