Re: checkbox checked?

From: Date: Sun, 22 Oct 2000 00:57:03 +0000
Subject: Re: checkbox checked?
References: 1 2  Groups: php.general 
Request: Send a blank email to php-general+get-21617@lists.php.net to get a copy of this message
I was think about something like this. if ($checkbox <= 0); echo "you must accept the rules, before you can join"; else Gary Mark Peoples wrote: > <?php > if(!$submit) > { > print("<form method=\"post\" > action=\"$PHP_SELF\">"); > print("<input type=\"checkbox\" name=\"box1\" > value=\"yes\" checked>Check > Box"); > print("<input type=\"submit\" > name=\"submit\">"); > } > if($submit) > { > if($box1 == "yes") > { > print("The check box was checked"); > //other code > } > } > ?> > > marco > > -----Original Message----- > From: Gary [mailto:deadfred@2die4.com] > Sent: Saturday, October 21, 2000 5:32 PM > To: php-general@lists.php.net > Subject: [PHP] checkbox checked? > > How would I check if a checkbox is checked? I have a form that will > require the one checkbox in it, to be checked. I have learned how to > validate mail, names, ETC, but I have run into a wall on this one. > > TIA > Gary > -- > The sad thing about artificial intelligence is that it lacks artifice > and therefore intelligence. Jean Baudrillard (1929), French semiologist. > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net -- The sad thing about artificial intelligence is that it lacks artifice and therefore intelligence.Jean Baudrillard (1929), French semiologist.

« previous php.general (#21617) next »