fopen with URL

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

here is my problem:
i can access from everywhere to a log file on my own web server (apache/php)
at home using a web browser:

So my web server is okay from outside.

But, i d'ont know why, i can't open the log file from a php script with the
fopen command:
fopen(" ","r")

Actually, if i run the php script from my web server, it is working fine.
But if i move the script on an external web server and run it i get this
error message:
....failed to open stream: Connection timed out in ...

If i replace "" by anyy other web server (like it is working fine!!!

Could you help me?

Why does my log file is accessible from outside using a direct acces with a
web browser( )  but not running the php script
from outside??



Re: fopen with URL

Rod wrote:
Quoted text here. Click to load it

Just a guess, but is your webserver behind a proxy? If so, the webbrowser
will be able to connect to the server through the proxy settings.

PHP can connect to proxies through the cURL extenstion, see for more info.

Let us know the real URL when you are not behind a proxy, so we can debug
the connection and possibly suggest a solution.


Site Timeline