<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD><TITLE>Message</TITLE>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.2800.1226" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT size=2>I didn't know there was a value attribute to the
<option> tag. Previously I'd set it up like:</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2><select></FONT></DIV>
<DIV><FONT size=2><option>Option 1</FONT></DIV>
<DIV><FONT size=2><option>Option 2</FONT></DIV>
<DIV><FONT size=2><option>Option 3</FONT></DIV>
<DIV><FONT size=2></select></FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>In which case if I selected Option 2 the value of the variable
sent would be "Option 2". So to be clear, if I use <option
value="value1">hoople</option> the value setting will replace
the "hoople" listed between the <option> and </option>
brackets? If so, sorry for asking something so trivial.</FONT></DIV>
<BLOCKQUOTE
style="PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV style="FONT: 10pt arial">----- Original Message ----- </DIV>
<DIV
style="BACKGROUND: #e4e4e4; FONT: 10pt arial; font-color: black"><B>From:</B>
<A title=mdougherty@pbp.com href="mailto:mdougherty@pbp.com">Mike
Dougherty</A> </DIV>
<DIV style="FONT: 10pt arial"><B>To:</B> <A title=javascript@LaTech.edu
href="mailto:javascript@LaTech.edu">'[JavaScript List]'</A> </DIV>
<DIV style="FONT: 10pt arial"><B>Sent:</B> Thursday, October 09, 2003 2:37
PM</DIV>
<DIV style="FONT: 10pt arial"><B>Subject:</B> RE: [Javascript] select list
option sending</DIV>
<DIV><BR></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2><select id='City'></FONT></SPAN></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2> <option value='17'>New
York</option></FONT></SPAN></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2> <option value='13'>Los
Angeles</option></FONT></SPAN></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2> <option
value='6'>Boston</option></FONT></SPAN></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2></select></FONT></SPAN></DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff
size=2></FONT></SPAN> </DIV>
<DIV><SPAN class=125443418-09102003><FONT face=Arial color=#0000ff size=2>when
the CITY gets back to the server it will have the ID value - since this is
basic HTML, there's no browser version/scripting issues
either.</FONT></SPAN></DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
<DIV></DIV>
<DIV class=OutlookMessageHeader lang=en-us dir=ltr align=left><FONT
face=Tahoma size=2>-----Original Message-----<BR><B>From:</B> <A
href="mailto:javascript-bounces@LaTech.edu">javascript-bounces@LaTech.edu</A>
[mailto:javascript-bounces@LaTech.edu] <B>On Behalf Of </B>David S
Levy<BR><B>Sent:</B> Thursday, October 09, 2003 1:11 PM<BR><B>To:</B>
[JavaScript List]<BR><B>Subject:</B> [Javascript] select list option
sending<BR><BR></FONT></DIV>
<DIV><FONT size=2>Hey. I'm trying to make a dropdown(select) list of
locations in a form, but instead of sending off the location name on
submittal, I'd like to send an associated location ID, since I'm working
with a database. I was wondering if I can set up a form element with a
name and without a type on selection of a given dropdown option. To
elaborate:</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>Let's say I have a dropdown list of the following
cities:</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>New York</FONT></DIV>
<DIV><FONT size=2>Los Angeles</FONT></DIV>
<DIV><FONT size=2>Boston</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>And each of these cities has associated with it a location
ID, like:</FONT></DIV>
<DIV><FONT size=2>New York - 17</FONT></DIV>
<DIV><FONT size=2>Los Angeles - 13</FONT></DIV>
<DIV><FONT size=2>Boston - 6</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>I'd like a way to list the cities but send the ID's.
Could I do something within the <option> tag like
onselect="this.form.city_ID=17" for New York? If yes, could
I just do it like that or would I need to declare the form
element city_ID as a hidden variable or something along those lines?
If not, does anyone have any ideas? I hope my javascript idea is
understandable, I'm just turning to this language in order to move along a
project that's primarily in PHP.</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>Thanks,</FONT></DIV>
<DIV><FONT size=2></FONT> </DIV>
<DIV><FONT size=2>David.</FONT></DIV>
<HR>
<PRE>The information contained in this communication may be confidential, is
intended only for the use of the recipient(s) named above, and may be
legally privileged. You are hereby notified that any dissemination,
distribution or copying of this communication and any of its contents or
attachments is strictly prohibited. If you have received this
communication in error, please notify us immediately by replying to this
message and please delete this message from all computers and servers.</PRE></BLOCKQUOTE>
<P>
<HR>
<P></P>_______________________________________________<BR>Javascript mailing
list<BR>Javascript@LaTech.edu<BR>https://lists.LaTech.edu/mailman/listinfo/javascript<BR></BLOCKQUOTE></BODY></HTML>