How to enable allow_url_fopen, allow_url_include on a shared server using custom php.ini

You can simply enable/disable the php functions allow_url_include and allow_url_fopen by editing the php configuration file. These functions may disabled in the php configuration file of some shared hosting server. You can simply manage these function by creating a custom php.ini file under your public folder.

Here is the way to do that 🙂

Step I : Create/Open php.ini file under the public folder of your domain.
Step II : Add the following lines to enable above php functions.

allow_url_fopen = On
allow_url_include = On

that’s it 🙂

Related Links:
.htaccess rules for not executing php in images folder
http to https redirection using .htaccess file
Disabling Magic Quotes using .htaccess file

Arunlal Ashok

Linux Server Administrator. I’m managing Linux servers since 2012. I started this blog to share and discuss my ideas.

Any questions? Write to arun (@)

You may also like...

1 Response

  1. Magesh says:

    Thanks Arun. That’s a genius idea 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *