URL file-access is disabled

URL file-access is disabled

Posted by: ToneHaven
Posted on: 2006-08-08 17:02:00

Hi, I just purchased a new hosting account and have uploaded my page but I get the following error:

Warning: file_get_contents(): URL file-access is disabled in the server configuration in /home/.gritz/tonehaven/tonehaven.com/index.php on line 6

You can see the full error here: http://www.tonehaven.com/

I searched for this and found this page: http://www.dotsilver.com/faq/120.html

"Your hosting provider prohibits function file_get_contents() to connect to foreign hosts. "

I would like to know how I can enable "connect to foreign hosts" as this is critical for my site to run?

I also sent this as a support ticket about 3 days ago and have not herd back which is very concerning and I'm regretting ever have purchased the service now as prompt support is critical.

Re: URL file-access is disabled

Posted by: seiler
Posted on: 2006-08-08 17:09:00

I believe you'll need to use cURL. Here's an article in the wiki that uses the same function you're using as an example:

http://wiki.dreamhost.com/index.php/CURL#Alternative_for_file_get_contents.28.29

wiki.dreamhost.com can come in handy, so I'd add that to your bookmarks as a reference.

Re: URL file-access is disabled

Posted by: ToneHaven
Posted on: 2006-08-08 19:00:00

thanks but I can't get this to work and have still not herd back from the tech support, do you know why they won't reply or is this common?

Re: URL file-access is disabled

Posted by: sdayman
Posted on: 2006-08-08 19:08:00

Terms of Service outline a 24 hour response time.

I've had good luck with using the cURL option. What happens when you try it?

-Scott

Re: URL file-access is disabled

Posted by: desilucy
Posted on: 2006-08-08 19:10:00

An alternative would be to install your own PHP5 and allow for URL fopens.

http://wiki.dreamhost.com/index.php/Installing_PHP5

Re: URL file-access is disabled

Posted by: ToneHaven
Posted on: 2006-08-08 23:18:00

I'm not that familiar with php and I think by looking at those instructions then it would be abit over my head but thanks for the suggestion.

The code I'm using is from laiwa.com, it is a template script that will load up on the server.

I ran it on another host recently and it worked fine and looks like this when running: http://www.freewirelessringtone.com/

I herd back from Tech and they just pointed me to the wiki and said they can't help further.

I'm unsure what to do, I don't want to use this service if I can't use remote files and I thought it would come witht the service like my other hosting. I wanted to also run other web sites on this hosting account that also use remote files using another script.

I could post the code but I think it would not post here on this forum?



Re: URL file-access is disabled

Posted by: ToneHaven
Posted on: 2006-08-08 23:31:00

I have requested a refund on my account as I don't want to deal with this hosting company if they can't offer standard features and faster support. I'm unsure if they will refund as I have also purchased a domain name with them, i guess I will have to wait another day or 2 just to find this out and see what I can do about this mess...

Re: URL file-access is disabled

Posted by: scjessey
Posted on: 2006-08-09 06:14:00

In reply to:

I have requested a refund on my account as I don't want to deal with this hosting company if they can't offer standard features


With most responsible webhosts, it is now standard practice to disable URL file access. You are likely to encounter this problem again. Your best bet is to contact the authors of the canned script you are trying to run, and ask them to provide a cURL-based alternative.

Re: URL file-access is disabled

Posted by: Jewels
Posted on: 2006-08-09 08:29:00

In reply to:

I have requested a refund on my account as I don't want to deal with this hosting company if they can't offer standard features and faster support. I'm unsure if they will refund as I have also purchased a domain name with them, i guess I will have to wait another day or 2 just to find this out and see what I can do about this mess...


DH can offer it, but they choose not to by default for security reasons. I can see things from your point of view, but I do recommend either learning how to modify the script, or seek an alternative script.

DH will be able to refund your hosting (assuming you paid by credit card), but not the domain name.

Re: URL file-access is disabled

Posted by: ToneHaven
Posted on: 2006-08-09 09:04:00

ok thanks for letting me know these things. I might keep the hosting since i got a discount and i can run a few other sites here i guess that don't use remote.

I think I will look at an alternative script tommorow or design and put that up for now... I think media plaza offer something similar...


Tags: file accesshosting providerhostsurlhttpsupport ticketserver configurationline 6uploadedphphtmlfaq