arn_php Posted February 25, 2008 Share Posted February 25, 2008 How do I override php.ini? I need to turn on the register_global into a website that requires it. but then the website is hosted in a shared hosting with others. the host is worry that it would impact others? So how do I use the .htaccess or ini_set() ? Please advise. Quote Link to comment Share on other sites More sharing options...
deansatch Posted February 25, 2008 Share Posted February 25, 2008 add this line to your .htaccess file php_value register_globals on But think carefully before you turn them on. Do you really need to? Can you not work without them and use $_GET, $_REQUEST etc... Quote Link to comment Share on other sites More sharing options...
revraz Posted February 25, 2008 Share Posted February 25, 2008 Rewrite the code so you don't need it. Quote Link to comment Share on other sites More sharing options...
Orio Posted February 25, 2008 Share Posted February 25, 2008 Can you not work without them and use $_GET, $_REQUEST etc... Rewrite the code so you don't need it. Probably 3rd party? Orio. Quote Link to comment Share on other sites More sharing options...
deansatch Posted February 25, 2008 Share Posted February 25, 2008 Probably 3rd party? Answer = Find new 3rd party Quote Link to comment Share on other sites More sharing options...
revraz Posted February 25, 2008 Share Posted February 25, 2008 Answer, so what, fix it anyways. Quote Link to comment Share on other sites More sharing options...
Orio Posted February 25, 2008 Share Posted February 25, 2008 Yeah, try and fix phpNuke for an example. Go for it. If he wants register_globals on, and he's aware of the risks, what do you care? Orio. Quote Link to comment Share on other sites More sharing options...
revraz Posted February 25, 2008 Share Posted February 25, 2008 What do you suggest when he updates to PHP 6? Quote Link to comment Share on other sites More sharing options...
Orio Posted February 25, 2008 Share Posted February 25, 2008 Look, I didn't say s/he's right or wrong. I said that s/he asked how s/he can turn on register_globals in shared hosting, when s/he doesn't have direct access to the php.ini. So why start telling him/her to rewrite the code? I think s/he is aware of the fact s/he can do that. Orio. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.