br3nn4n Posted November 24, 2008 Share Posted November 24, 2008 Why does it just make the action index.php ? I need it to send to index.php?var=foo&bar=yea, because the rest of my script depends on that to decide what page to display. Any ideas? Thanks!! Link to comment https://forums.phpfreaks.com/topic/133988-cant-set-form-action-to-indexphpvarfoobaryea/ Share on other sites More sharing options...
ratcateme Posted November 24, 2008 Share Posted November 24, 2008 what do you mean "auction" it calls index.php with the vars $_GET['var'] equaling 'foo' and $_GET['bar'] equaling 'yea' Scott. Link to comment https://forums.phpfreaks.com/topic/133988-cant-set-form-action-to-indexphpvarfoobaryea/#findComment-697460 Share on other sites More sharing options...
Mchl Posted November 24, 2008 Share Posted November 24, 2008 You need to have foo and bar as hidden fields in your form (and form method='get') Link to comment https://forums.phpfreaks.com/topic/133988-cant-set-form-action-to-indexphpvarfoobaryea/#findComment-697464 Share on other sites More sharing options...
br3nn4n Posted November 24, 2008 Author Share Posted November 24, 2008 Oh okay and then just set the method to get. Got it. Just out of curiosity any way to do this via post? Link to comment https://forums.phpfreaks.com/topic/133988-cant-set-form-action-to-indexphpvarfoobaryea/#findComment-697490 Share on other sites More sharing options...
Mchl Posted November 24, 2008 Share Posted November 24, 2008 Yes. Modify your index.php file to use $_POST instead of $_GET for these variables (or if you need both, you may use $_REQUEST) Link to comment https://forums.phpfreaks.com/topic/133988-cant-set-form-action-to-indexphpvarfoobaryea/#findComment-697493 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.