Re: Re: radio form submission
| From: | Vitalii Demianets | Date: | Sat, 25 Jun 2011 08:20:59 +0000 |
| Subject: | Re: Re: radio form submission | ||
| References: | 1 2 3 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-313716@lists.php.net to get a copy of this message | ||
On Friday 24 June 2011 21:44:05 Chris Stinemetz wrote:
> if (!array_key_exists($_POST['store_type'], $choices)) {
>
>
>
> echo "You must select a valid choice.";
Nothing wrong to me. Perfectly valid way of checking if there is at least one
selected radio button (I prefer isset($_POST['store_type']), but that is just
a matter of taste).
Some debugging can help you. Try insert this:
var_dump($_POST['store_type']);
var_dump($choices);
just before validation if (!array_key_exists(...
HTH