How to enable URL file-access in the server configuration or Godaddy server

January 5, 2010 | Filed Under Others | 5 Comments

If you are getting Warning Messages like this one

Warning: include() [function.include]: URL file-access is disabled in the server configuration in /home/xxxxxxxxxxxxxxxxxxxxxxxxxx/filecall.php on line 5

Where xxxxxxxxxxxxxxxxxxxxxxxxxx < your server path. It ‘s means that your server configuration is blocking external file access( include () function in many cases). To solve this issue you need to set allow_url_fopen= ON and allow_url_include =ON in PHP configuration (php.ini). If you have not dedicated server, You need to ask for your service provider to set allow_url_fopen= ON, allow_url_include =ON If you want enable URL file-access setting=on via .htacess
then you need to write php_value allow_url_fopen 1 in .htacess file.
If you want to enable URL file-access via PHP.
Then you need to write <?php
ini_set(‘allow_url_fopen’,’ON’) ; // ON or 1 both are same
ini_set(‘allow_url_fopen’,’ON’) ;

I suggest a solution simple use file_get_contents()instead of include() function.
In this case you don’t need to enable URL file-accessin the server configuration.

Basically Godaddy server doesn’t support include() function due to disable allow_url_fopen.


5 Responses to “How to enable URL file-access in the server configuration or Godaddy server”

  1. The writer of has written a superior article. I got your point and there is nothing to argue about. It is like the following universal truth that you can not disagree with: The amount of work you put into a project is inversely proportional to how much your boss/professor/higher-than-you I will be back.

  2. What a great resource!

  3. Hello! dkgekec interesting dkgekec site!

© 2009 - 2015

eXTReMe Tracker