Page 1 of 1

windows 2000, apache 2, php 4 falies to open online files

Posted: Mon Apr 17, 2006 2:23 pm
by oran
Hi,
I'v installed a server on my computer to develop my site.
When I try to read online files (google.com, for example) with, for example, file_get_contents I get this msg (from windows):

Code: Select all

php.exe has genereted errors and will be closed by Windows. You will need to restart the program.
and this one from apache (as HTML):

Code: Select all

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator, oran@localhost and inform them of the time the error occurred, and anything you might have done that may have caused the error.

More information about this error may be available in the server error log.
I couldn't find any log file.

The exact code that I tried to run is:

Code: Select all

$contents = file_get_contents("http://www.google.com/search?q=dog");
Any have any idea how can I solve this problem??

tnx,
Oran.
[/quote]

Posted: Mon Apr 17, 2006 2:55 pm
by feyd
Check your error logs, might get a better clue from there.

Posted: Mon Apr 17, 2006 3:14 pm
by oran
Where can I find the log file?

Posted: Mon Apr 17, 2006 3:17 pm
by John Cartwright
typically the php error log is found in /apache/logs/

Posted: Mon Apr 17, 2006 3:36 pm
by oran
I find this error (in error.log):

Code: Select all

[Mon Apr 17 23:35:22 2006] [error] [client 127.0.0.1] Premature end of script headers: php.exe, referer: http://localhost/

Posted: Tue Apr 18, 2006 6:32 am
by oran
I fixed the problem by installing XAMPP.
tnx any way...