How to enable register_globals for PHP5?

by Stephen on September 26, 2008

 
If your server is configured with suphp, here is now to enable register_globals for php5:

  1. Create a file named php.ini and insert this into it:

    register_globals = On

  2. Upload this file to inside your public_html folder
     
  3. Create a file named .htaccess and put this into it:

    SuPHP_ConfigPath /home/acc_username/public_html/php.ini

    Where acc_username is your account username

  4. Put this .htaccess into inside public_html and that should be it.

 

If your server doesn’t have suphp, here is how to enable register_globals:

  1. Create a file named .htaccess and put this into it:

    php_value register_globals 1

  2. Upload this .htaccess to inside your public_html folder
     
  3. Done

 

{ 5 comments… read them below or add one }

acctman August 28, 2009 at 9:33 am

does SuPHP_ConfigPath /home/acc_username/public_html/php.ini mean /opt/suphp/etc/suphp.conf /home/site1/public_html/php.ini

Reply

admin August 28, 2009 at 11:33 am

It means:

SuPHP_ConfigPath /home/site1/public_html/php.ini

Reply

Brian February 7, 2011 at 1:16 am

Thanks for the info my host has upgraded to php 5.3 and the first solution work like a charm . thanks mate

Reply

The Kakang April 6, 2011 at 6:42 pm

wow, it’s work…!!!! great tutorial.
i’ve been test it in the my server hosting wich disable register global and now, it enabled.
Thanks.

Reply

Manish September 4, 2011 at 8:31 pm

Realy working……thanks

Reply

Leave a Comment

Previous post:

Next post: