I have the following function :
function doParse($parser_object) {
$links=file("./fullsoccer.TXT", "r");
$i=0;
while(!empty($links[$i]))
{
set_time_limit(0);
if (!($fp = fopen($links[$i], "r")));
{
//loop through data
while ($data = fread($fp, 4096)) {
//parse the fragment
xml_parse($parser_object, $data, feof($fp));
}
}
$i++;
}
}
This code save a list of 507 links of XML data from fullsocce.txt into $links then I read the content of each file (link: online links) using fread and pass the $data to my main function which is xml_parse to parse and save the data using SAX parser . my problem is: just that last file of the array $links is passed to the function and parse the data , I want your help to know why it is working just with one file? please It is an emergency case