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

How to enable allow_url_fopen, allow_url_include?

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 🙂

How to disable phpinfo(); in a shared environment/hosting?

The phpinfo() function in php has a lot of uses. Before going to disable the phpinfo function,you must learn the basics of it. Here is the link which helps you to create the phpinfo >> phpinfo() <<

What is phpinfo() function ?

The function phpinfo() displays the current information of PHP, which includes the php extensions and compilations, version, server information and environment (if compiled as a module), the PHP environment, paths, master and local values of configuration options, HTTP headers, and the PHP License etc.

You will get the PHP informations not only from the browser but also from the server command-line. READ MORE…

Related Links:

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

Post navigation

Arunlal Ashok

Linux Systems Architect at Endurance International Group. I know her (Linux) since many years. Linux lover. Like to play on Linux console. I started this blog to share and discuss Linux thoughts.

Always happy for an open discussion! Write to arun (@) crybit (dot) com. Check about me for more details. About this blog and our strong members, check The team CryBit.com

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

Leave a Reply

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