RE: [PHP-WIN] How to get the Option Value?

From: Date: Sat, 28 Apr 2001 06:15:38 +0000
Subject: RE: [PHP-WIN] How to get the Option Value?
Groups: php.windows 
Request: Send a blank email to php-windows+get-7111@lists.php.net to get a copy of this message
I made one childish mistake. Sorry to bother you. Regards, Weidong Gu -----Original Message----- From: Gu Weidong-a1923c [mailto:a1923c@motorola.com] Sent: Saturday, April 28, 2001 1:55 PM To: php-windows@lists.php.net Subject: [PHP-WIN] How to get the Option Value? I try to create the dynamic list and want to get the selected value. But every time I got the '2001' whatever I selected from the list. Like to hear your advice. Thanks, Weidong ------------------------------------------------------------------------------------------------------------------------- /*test_option.php*/ <?php $today=getdate(); $year=$today[year]; ?> <html> <body> <form action="test_option.php" method="post"> Year<SELECT NAME="year"> <OPTION VALUE="" SELECTED> <? for ($i=0; $i<= 10;$i++) { ?> <OPTION VALUE=<?echo $year-$i;?>><?echo $year-$i;?> <?}?> </SELECT> <input type="submit"> </form> </body> </html> <?php echo $year; ?> -- PHP Windows Mailing List (http://www.php.net/) To unsubscribe, e-mail: php-windows-unsubscribe@lists.php.net For additional commands, e-mail: php-windows-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.windows (#7111) next »