What are causes of a connection-timeout with fopen()?
Posted on
16th Feb 2014 07:03 pm by
admin
Hello! Here is the situation: The server I host my website on just upgraded it's PHP build from 4.4.* to 5.2.4. Not just PHP was upgraded, MySQL, postGres, and (I think) Apache were upgraded as well. Before the upgrade, my site worked perfectly.
But now, whenever I access my site, it takes a long time to complete a request and all that is returned is "Warning: fopen(<THE_URL>) [function.fopen]: failed to open stream: Connection timed out in..."
Did you know?Explore Trending and Topic pages for more stories like this.
I know where the error is -- it's in my templating class. I check the remote server's configuration and the directive "allow_url_fopen is enabled and safe_mode is disabled.
The strange thing is that my script works on my local server perfectly which is using PHP build 5.2.5. I looked for any differences between my local-server's PHPINFO() and my remote-server's PHPINFO() and, while I didn't find anything eye-catching yet, I noticed that virtual-directory-support is disabled on my remote-server and it is enabled on my local-server. Would that be what's causing the problem? If not, what are some potential causes for fopen() to behave this way?
No comments posted yet
Your Answer:
Login to answer
228
12
Other forums
Output Buffering question
Hi all,
I've been trying to wrap my head around output buffering. So far I've found tons of
SMTP server...
I recently found a tutorial online on SMTP authentification for sending emails from webpages, here i
Problem with Sending Mail by PHP
hello all,
I m new to php, can u plz provide me the code to send mail by php having CAPTC
How do I get the row number from from an sql table query
Hi all
I have a table that I query and it returns a number of rows.
mysql_num_rows($query)
Connect to database that isn't localhost
I am currently doing a small script for a company that doesn't have mySql support on there hosting.
php mysql query from input textbox
Hi,
I have a text box, in that i have given the mysql query. I can able to get the query in v
check comment for html
hi, I just wanted to check if a comment a user posts contains HTML, and if it does, to not allow it
cURL and Sessions
Ohai.
So, I'm trying to cURL a bunch of things off of a page, and put them into a session. I'
Anti Spam Code Problems
Ok where do i start? Probably by telling you I have very little working knowledge of PHP and that I
Cron Job and Output
I have php codes running under a cron job.
But everytime i output (echo) , it comes out as comple