Forum Moderators: coopster

Message Too Old, No Replies

PHP Include command stopped working

Page to be included works fine but ...

         

HeyJim

5:27 pm on Aug 19, 2005 (gmt 0)

10+ Year Member



This is actually a problem with my hosting company which is refusing to respond to my support messages. Which means I'll be leaving them very soon. It's just making the time in a hectic schedule for one more unexpected project that I'm hoping to delay.
Anyway, it involves php so I'm hoping someone here might be able to give me a work around.
Site A generates a page (which is displaying fine) which in turn is "included" on a page of another site using the php include (command? directive?). It's been working fine for the last year or so. The hosting company rebooted the server the other day and now although the originating page displays fine on Site A, Site B now displays this:
Warning: main(http://some.site.com): failed to open stream: HTTP request failed! HTTP/1.1 403 Forbidden in d:\html\users\sitea\html\links.php on line 124

Warning: main(): Failed opening 'http://some.site.com' for inclusion (include_path='.;c:\php4\pear') in d:\html\users\sitea\html\links.php on line 124

-------------------------------------------------------
I don't see how if the original page is displaying fine on its domain why there would be a problem "including" it on another domain using the php include. Doesn't make sense to me. Is there a work around for this? Is there something obvious the hosting company needs to know? I mean, I just found out that most of their support people don't have a clue what an .htaccess file is so they probably don't have a clue what's wrong with the server. And, I sure don't. But that's one reason I pay them every month: to know this stuff. Maybe they're not reponding to my pleas for help because they don't know how to fix the problem.
Any help greatly appreciated.

mack

2:47 pm on Aug 20, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



This is a long shot, but have you set the correct file permissions for the file you wish to include?.

Mack.

HeyJim

3:10 pm on Aug 22, 2005 (gmt 0)

10+ Year Member



Yes, but it still doesn't work. Great thought but just didn't make the difference. Thanks for the try though.

p1lky

3:47 pm on Aug 22, 2005 (gmt 0)

10+ Year Member



It may be that the host, while doing their reboot, closed up a security hole to prevent users from accessing other peoples files. You have sitea and siteb, somebody else has sitec and you could theoretically include sitec files in your own. My old host did this without warning, and I had quite a lot of stuff on there relying on their little oversight.

mack

4:48 pm on Aug 22, 2005 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



I think p1lky may well be right.

I think it is a php settign that determines if you can include remote/local files. This is part of the servers php.ini file and is somethign clients on the server do not have control over.

It's not good however if your host doesn't respond to your support questions, or inform you of system configuration changes.

Mack.

HeyJim

5:39 pm on Aug 22, 2005 (gmt 0)

10+ Year Member



Thanks. It looks like we're on to the problem. Anyone have any idea if it's just one or two php.ini settings that have to be changed and, if so, what they should be changed to?

I've already moved my two most important sites to another company but moving this one is so involved that it would be nice to tell the hosting company how to resolve the problem. Hey, they might even listen and do something!

Well, ok, not likely. And, how stupid is it for them to ignore legitimate hosting problems? Their forum is filling up with people saying, "Hey, say something. Anything! Let us know you're working on the problem. Don't just ignore me." And, I think they're a pretty well known hosting company. And, I'm not talking $5.00 a year hosting. I pay them $35.00 monthly. A tiny amount compared to what many others are paying but I think for $420.00 a year I and the others at least deserve a response.

Oh, well, keep it in perspective. It's only a hosting problem. Others have severe health problems, serious family problems, bombs in their back yard, etc.