RE: [PHP] verifying that a dropdown was selected

From: Date: Thu, 05 Jul 2001 10:57:37 +0000
Subject: RE: [PHP] verifying that a dropdown was selected
Groups: php.general 
Request: Send a blank email to php-general+get-56290@lists.php.net to get a copy of this message
<select size=1 name=month> <option value=0 selected>Select month <option value=1>January . . . </select> . . . if(!$month) { // please select month } else { // month selected } > -----Original Message----- > From: Richard Kurth [mailto:rkurth@pacifier.com] > Sent: 5 iulie 2001 12:36 > To: php > Subject: [PHP] verifying that a dropdown was selected > > > > I have a dropdown box that is for selecting the month How can I be > verified that the customer has selected one of the months. I am using > verification like this but it does not do what I want for a dropdown > box it works fine for regular fields > > if ($month == "") { > > $month_err = " > <font color=red>Please enter the Month of > expiration!</font><br> > "; > $send = "no"; > > > > > <select name='month' size='1'> > <option value='00' ></option> > <option value='01' >01</option> > <option value='02'>02</option> > <option value='03'>03</option> > <option value='04'>04</option> > <option value='05'>05</option> > > > > > > > > > > > > Best regards, > Richard > mailto:rkurth@pacifier.com > > > -- > 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 > >

« previous php.general (#56290) next »