How to change a php.ini value?

We use suPHP in all of our servers. This is the common reason why php_flag or php_value doesn't work on CH servers. To change a value like "register_globals" or other you need to use a custom php.ini file put in the public_html folder. Suppose, if you want to change the value of register_globals using a custom php.ini file, just put the following inside a php.ini file created on your public_html folder:

register_globals = On

It should set your register_globals value to On, If you want to set the value to Off, use the following:

register_gloabls = Off

Use the same settings for all available php.ini values to be configurable by users.

After you are done with setting up php.ini file, you need to set the suPHP configpath so that all other subdirectories in your public_html takes that php.ini as its default configuration file. To do this put the following line in your .htaccess:

suPHP_ConfigPath /home/username/public_html

You need to change two things to correct values from your account settings. Username set at the above configuration is your cpanel username. You also need to find what home directory you are on, if it is /home, you do not need to do any changes above, but if it is /home2 or /home3 etc, you need to change with correct values. This settings can be found in your file manager or Go to Cpanel and from the left menu find out the path to your "Root Directory" or "WWW Directory" or "Home Directory".

Thats it, you should be all ON :)

  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

.htaccess - Fun with it !

Introduction The Apache web server has a number of configuration options that are available to...

500 Internal Server Error

Internal Server Error help, 500 error Internal server errors can be caused by a few different...

Cant Access my site?

We receive lots of queries from our client saying that why i'm not being able to access my site....

Do you provide AwStats?

Yes, we provide AWSTATS most of the servers of and it is updated automatically...

How to Block certain IP address?

Web servers can host many different domains on one hosting account under Linux/Apache, and...