Hardwarez Posted October 13, 2006 Share Posted October 13, 2006 Ok, my proram is working off post data. I have run into a place where I need to be able set a post name and value without using a form. How can I do that?I catch submitted forms like this:if ($_POST['looking'] == 'Button A') dosomething();So how do I set a post value named looking to "myValue"?Without a button or form.. Quote Link to comment Share on other sites More sharing options...
akitchin Posted October 13, 2006 Share Posted October 13, 2006 simple:[code]$_POST['looking'] = 'myValue';[/code]superglobals are ALWAYS initiated, whether they contain anything or not. that means you are always able to add values to them dynamically without having to force the engine to initiate them. Quote Link to comment Share on other sites More sharing options...
Hardwarez Posted October 13, 2006 Author Share Posted October 13, 2006 GR8! Thank you.. :) 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.