RE: [PHP] Re: Best way to test for form submission?
| From: | tedd | Date: | Sat, 29 Aug 2009 13:29:56 +0000 |
| Subject: | RE: [PHP] Re: Best way to test for form submission? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-297474@lists.php.net to get a copy of this message | ||
At 1:18 AM -0700 8/29/09, Warren Vail wrote:
To test a form I usually send the form contents to a php file that contains the following; foreach($_POST as $nm => $val) echo "_POST[".$nm."] [".$val."]<br>"; foreach($_GET as $nm => $val) echo "_GET[".$nm."] [".$val."]<br>"; Checkboxes and radio buttons only send their value if the control is "checked".That's correct, here's the way I solve both types: http://php1.net/b/form-radio http://php1.net/b/form-radio1 http://php1.net/b/form-checkbox/ http://php1.net/b/form-checkbox1/ Cheers, tedd -- ------- http://sperling.com http://ancientstones.com http://earthstones.com