Re: PHP and Form Values

From: Date: Fri, 27 Oct 2000 05:40:27 +0000
Subject: Re: PHP and Form Values
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-22271@lists.php.net to get a copy of this message
On Fri, 27 Oct 2000, Kyle Mathews wrote: > Hello: > How do you reference form select values in PHP. > Similar to how JavaScript handles form values. > Ex. document.formname.textname.value > > I imagine it is something similar to JavaScript, but I need it for select > boxes. > > Thanks, > Kyle The name assigned in the SELECT tag is the variable name in PHP - preceded by a $ sign of course. So if you do <SELECT NAME="choice">blah</SELECT> you can reference the selected value by $choice in the script called by the form's action. -- David Robley | WEBMASTER & Mail List Admin RESEARCH CENTRE FOR INJURY STUDIES | http://www.nisu.flinders.edu.au/ AusEinet | http://auseinet.flinders.edu.au/ Flinders University, ADELAIDE, SOUTH AUSTRALIA

« previous php.general (#22271) next »