SJF Posted July 4, 2009 Share Posted July 4, 2009 Hey guys! Brand new to the forums, so first of all I'd like to say thanks for taking time to read this! I'm broken this down as basic as possible for assistance. The Code that is in both links (include.php) below: <?php include("http://www.toyrecruiter.com/content/?p=3");?> The Error [pre]Warning: include(content/index.php?p=3) [function.include]: failed to open stream: No such file or directory in /home/content/g/r/e/greattoysearch/html/toyrecruiter/include.php on line 1 Warning: include() [function.include]: Failed opening 'content/index.php?p=3' for inclusion (include_path='.:/usr/local/php5/lib/php') in /home/content/g/r/e/greattoysearch/html/toyrecruiter/include.php on line 1[/pre] The Situation I'm using PHP includes to pull string data from a single Wordpress post so I can place it anywhere on the page. I've done it with multiple sites in the past with absolutely no problem. Working vs Non-Working Examples Working: http://www.sjf.me/include.php Non-Working: http://www.toyrecruiter.com/include.php Other Forum's Solutions Other people have had similar issues and here are some of the solutions they provided: Edit / Create PHP.ini to include allow_url_fopen = on as well as allow_url_include = on Did this. And I've saved it as both PHP.ini as well as PHP5.ini (since that's what they said to save it as if you have PHP5 installed). I -can- downgrade to PHP4 (GoDaddy allows me to do this) but I have not tried this. Call your Hosting Service Did this. They claim everything is fine on their end. I even asked why it works when I link to their server (toyrecruiter.com) via my other server (www.sjf.me - hosted through HostMonster) and still they say the PHP is working fine. Didn't help at all. Use cURL instead of php includes Did this. It does not work for me. I'm not sure why, but basically it shows up completely blank as if it wasn't bringing the data into the variables or something. Not to mention, there is no reason I should have to go this route if it is working perfectly fine on another server. Edit your .htaccess to point to a local PHP.ini file where you can change allow_url_fopen and allow_url_include I have not done this, but if anyone can point me in the right direction to do this, or feel it might solve the problem, please do! I'm at a complete loss. This website is for a client, and they have already paid for hosting from GoDaddy for a while so switching hosting services is not a choice (or at least not one I think they'll want to do). www.sjf.me is hosted with HostMonster.com with PHP 5 www.toyrecruiter.com is hosted with GoDaddy.com with PHP 5 Thanks again for taking the time to read this and hopefully someone has a solution! Happy 4th of July! Quote Link to comment Share on other sites More sharing options...
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.