hi!
My server is running apache 1.3.2 with php 4.06 on win2000. I am trying to extract the content from a csv file using fgetcsv. But everytime i run the scripts, php.exe error occurs and internal server error displayed. I checked the log and it is identified as " Premature end of script headers: e:/php4/php.exe".
This error happens only when i trying to read a large file (approx. 46K). each line is approximately 1-2K and One of the field is description and therefore took up approx. 1K. I tried to changed the php maximum execution time but find that the result is still the same.
I suspect it is the maximum length problem, but cannot find in the manual about the limit. Following is my code...
$fp = fopen ("$csv_file_name","r");
while ($data = fgetcsv ($fp, 5000, ",")) {
$csv_data[$row] = $data;
$row++;
}
fclose ($fp);
please advice and thank you in advance for your help..
from
Desmond