Invalid Stream Source
Posted: Sat Mar 27, 2004 2:18 pm
This seemed more like a PHP error than an XML one, so here it goes.
I am reading up on how to get data from XML into PHP. The URL I got the info from is here.
Anyway, I do the stuff exactly as they say, and this is the error that returns:
Warning: feof(): supplied argument is not a valid stream resource in c:\program files\easyphp1-7\www\xml\bookreader.php on line 17
Line 17 and thereabouts is:
I am reading up on how to get data from XML into PHP. The URL I got the info from is here.
Anyway, I do the stuff exactly as they say, and this is the error that returns:
Warning: feof(): supplied argument is not a valid stream resource in c:\program files\easyphp1-7\www\xml\bookreader.php on line 17
Line 17 and thereabouts is:
Code: Select all
<?php
$fp = fopen("books.xml", "r");
$doc = fread($fp,100000);
xml_parse($parser, $doc, feof($doc));
?>