ruski Posted December 16, 2009 Share Posted December 16, 2009 Hi friends, I have a little problem. Just switched server and most of my code is broken due to a lot of form posted variables being retrived by using its variable name e.g: $variable = $variable; and not $variable = $_POST['variable']; I was wandering what is the name of the php config that I can alter to enable my code to work in such a way again. Thanks in advance Quote Link to comment https://forums.phpfreaks.com/topic/185357-getting-posted-values-using-var-not-_postvar/ Share on other sites More sharing options...
cags Posted December 16, 2009 Share Posted December 16, 2009 The setting is register_globals, but you should change your code not the setting. Quote Link to comment https://forums.phpfreaks.com/topic/185357-getting-posted-values-using-var-not-_postvar/#findComment-978508 Share on other sites More sharing options...
ruski Posted December 16, 2009 Author Share Posted December 16, 2009 Thanks cags, I would love to fix the code but its about 300 files of it and I am doing a ground up rebuild next summer so Ill wait till then Quote Link to comment https://forums.phpfreaks.com/topic/185357-getting-posted-values-using-var-not-_postvar/#findComment-978512 Share on other sites More sharing options...
PFMaBiSmAd Posted December 16, 2009 Share Posted December 16, 2009 register_globals have been complete removed in php6, so you will need to correct your code before it will work under php6. register_globals being on also allow hackers to set session variables by simply putting same name GET parameters on the end of the URL when they visit your pages. Quote Link to comment https://forums.phpfreaks.com/topic/185357-getting-posted-values-using-var-not-_postvar/#findComment-978515 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.