GetDotted Domains

Viewing Thread:
"PHP - file_get_contents problem on freeola website"

The "Freeola Customer Forum" forum, which includes Retro Game Reviews, has been archived and is now read-only. You cannot post here or create a new thread or review on this forum.

Thu 17/02/05 at 09:20
Regular
Posts: 5
Help please...
I'm trying to read in a rss file using php.
I can't get this to work on my freeola website.
This is the code I'm using...

$file = "http://www.thelocal.se/RSS/theLocal.xml";
$filetext = file_get_contents($file);
?>

I get this error...

Warning: fopen(http://www.thelocal.se/RSS/theLocal.xml): failed to open stream: Permission denied

The remote site file loads fine when I type the url direct in to my browser.
The code works fine when testing on another server, but it won't work when uploaded to my freeola webspace.

Am I doing something really stupid?
Have freeola blocked this method of getting files from other websites?
Has anybody been able to get round this?
Thanks in advance to anybody who can solve this.
Thu 17/02/05 at 09:20
Regular
Posts: 5
Help please...
I'm trying to read in a rss file using php.
I can't get this to work on my freeola website.
This is the code I'm using...

$file = "http://www.thelocal.se/RSS/theLocal.xml";
$filetext = file_get_contents($file);
?>

I get this error...

Warning: fopen(http://www.thelocal.se/RSS/theLocal.xml): failed to open stream: Permission denied

The remote site file loads fine when I type the url direct in to my browser.
The code works fine when testing on another server, but it won't work when uploaded to my freeola webspace.

Am I doing something really stupid?
Have freeola blocked this method of getting files from other websites?
Has anybody been able to get round this?
Thanks in advance to anybody who can solve this.
Thu 17/02/05 at 09:42
Regular
"Pouch Ape"
Posts: 14,499
Has it worked before?

Try going in your ftp to where the httpdocs/htdocs folder is, right-clicking and changing the permissions settings to all. That happened to me once when a FREEOLA site crapped up - they'd moved a server and the settings defaulted!

Also, I've never seen that method before - is it valid (Garin will know this, and so will PHP.net if I could be bothered to look). Try using a simple include, or an fopen command instead.
Thu 17/02/05 at 10:27
Regular
Posts: 5
Thanks for that monkey-man

Unfortunately fopen gives the same error

I'll check the permissions on htdocs when I next get a chance to ftp
Thu 17/02/05 at 10:54
Regular
"It goes so quickly"
Posts: 4,083
It is a valid method, but (I could be wrong) I think Freeola disabled the ability to access remote files (files from another web server via HTTP) when they upgraded their customer servers.
Thu 17/02/05 at 14:19
Regular
"Fruit makes you far"
Posts: 232
'tis not allowed.
Thu 17/02/05 at 14:42
Regular
Posts: 5
Torquay United! wrote:
> 'tis not allowed.

That's disappointing.

So just to make sure....
You are saying that the only way I am going to be able to fetch rss files from other sites is by moving my domain to another ISP where they *do* allow the use of file_get_contents etc.

Is there no way to allow this facility on freeola?
Thu 17/02/05 at 15:33
Regular
"Fruit makes you far"
Posts: 232
The security risks of this feature were the reason we needed to disable it.

It may be that a future hosting product offers this service but I have nothing concrete at the moment.

The othing we offer is a virtual dedicated server at £25 per month - and because you're in your own virtual environment, you can make the box as secure or insecure as you wish.

Sorry can't be more help.
Thu 17/02/05 at 15:45
Regular
"Devil in disguise"
Posts: 3,151
Torquay United! wrote:
> The security risks of this feature were the reason we needed to
> disable it.

Just to clarify, the feature thats been turned off is outside connections as opposed to URL wrappers for fopen/file_get_contents being off?

What I'm trying to ask is, will fsockopen still work? Just wondering if Bob could use that instead of fopen.
Fri 18/02/05 at 10:14
Regular
Posts: 5
Garin wrote:
> What I'm trying to ask is, will fsockopen still work? Just wondering
> if Bob could use that instead of fopen.

I thought about trying this but I haven't quite worked out how to use it yet.
If Torquay says it will work then I'll have a go.
Fri 18/02/05 at 10:50
Regular
"NULL"
Posts: 1,384
Upload a phpinfo() file and see exactly what is enabled and what is disabled.

Freeola & GetDotted are rated 5 Stars

Check out some of our customer reviews below:

Impressive control panel
I have to say that I'm impressed with the features available having logged on... Loads of info - excellent.
Phil
LOVE it....
You have made it so easy to build & host a website!!!
Gemma

View More Reviews

Need some help? Give us a call on 01376 55 60 60

Go to Support Centre
Feedback Close Feedback

It appears you are using an old browser, as such, some parts of the Freeola and Getdotted site will not work as intended. Using the latest version of your browser, or another browser such as Google Chrome, Mozilla Firefox, or Opera will provide a better, safer browsing experience for you.