Dreamhost can't pull files from Wordpress (Error?)




I am getting the following error messages on my website:

Warning: file_get_contents(http://aboutfacetheatre.com/wp/?page_id=2815) [function.file-get-contents]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/aboutfacetheatre/aboutfacetheatre.com/index.php on line 317

Warning: file_get_contents(http://aboutfacetheatre.com/wp/?page_id=3) [function.file-get-contents]: failed to open stream: HTTP request failed! HTTP/1.1 404 Not Found in /home/aboutfacetheatre/aboutfacetheatre.com/index.php on line 351

I can’t seem to find the inconsistencies in the code - but they are all with the “file_get_contents” command.

The lines of code with errors are:

  $strSpotlight = file_get_contents($HTTP_WP_ROOT . '?page_id=2815');


    echo file_get_contents($strRoot . $strQuery);

We have been having a lot of trouble with our site over the past three weeks, but I finally updated the php last Friday. The website was stable and functional. Today, this error appeared when I came back from lunch - I don’t think it was anything I had done to cause it.

Any advice on fixing this dreamhost-wordpress connection?



It looks to me as if you may have inadvertently enabled “pretty permalinks” on the WordPress instance that is backing your site — for instance, if you try loading it up in a browser, the first link in your error message (http://aboutfacetheatre.com/wp/?page_id=2815) is redirecting to the nonexistent page http://aboutfacetheatre.com/spotlight/. You may need to disable pretty permalinks in your WordPress console.

This is, honestly, a pretty strange way to have your site set up. I’d strongly recommend that you try to figure out a way to have the whole thing use WordPress, rather than using it as a “back end” for specific pieces of content, or switch to another CMS (such as Joomla or Drupal) if WordPress cannot do the job on its own.


That did it! Thank you so much, Andrew. I appreciate your help.

I completely agree with you. If this were my decision or my company - I would absolutely do it differently. Unfortunately, I’m only here for a short time. They are going to be developing a new website in the next year, and I will recommend that they not use the Wordpress as a back end anymore.

Thanks for your help.