How can I change php values globally on my VPS?

This answer explains how you can change the global php settings on your VPS server.

This article applies to Linux Virtual Private Server accounts.

 

Depending on whether you want to edit the PHP values for the Apache or CGI version, please edit 1 of the following file paths below:

Apache file path

/etc/php5/apache2/php.ini

CGI file path

/etc/php5/cgi/php.ini

For example: to turn register_globals on you will need to change the line;

register_globals = Off
to
register_globals = On.

This will turn register_globals on for every domain on the VPS unless a domain has a different value specified in its vhost.conf file.

Answer options

Your feedback was successfully added.

Answer tracking

Track

Watch the content of this article for changes.