Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > Javascript > populate drop down menu

Reply
Thread Tools

populate drop down menu

 
 
bwv871
Guest
Posts: n/a
 
      02-15-2004
Hello. In the form below I have two drop down menus; the customer selects a
recipient and then selects a subject. I would like to change the way this
works so that if the customer selects "information" in the first menu, for
example, then only two options (information and returns) are available in
the second drop down menu; selecting "sales" in the first menu would make
only "products" and "models" available in the second drop down menu, etc. I
am a complete beginner and would appreciate any modifications to the html
below that would make this new functionality possible.
Thank you.

<html>
<head>
<title>Contact us</title>
</head>
<body>

<p>Please use the form below to send us an email. Choose an addressee from
the drop down list.

<form name=form action=cgi-bin/formmail22.pl onSubmit="submitonce(this)"
method=post>
<table cellpadding="0" bgcolor="#ffffff">
<tr><td><h4>Name:</td><td>
<input type="text" name="realname">
</td></tr>
<tr><td align="left"><h4><b>Email:</b></td><td>
<input type="text" name="email"></td></tr>
<tr>
<td align="left">
<h4><b>To:</b></td>

<td>
<select name="recipient">
<OPTION value='' >Please select...</OPTION>
<option value='' >Information</option>
<option value=''>Sales</option>
<option value='' >Advertising</option>
<option value=''>Webmaster</option>
</td></tr>

<tr>
<td align="left"><h4><b>Subject:</b></td><td>
<select name="subject">
<OPTION value="" >Please select...</OPTION>
<option value="information" >General Information</option>
<option value="returns">Returns policy</option>

<option value="products">Products</option>
<option value="models">Models</option>

<option value="rates">Ad rates</option>
<option value="criteria">Ad criteria</option>

<option value="problem">Report a problem</option>
<option value="Other">Other</option>

</select>
</td>
</tr><tr>
<td><h4>Message:</td></tr><tr><td colspan="5">
<textarea name="message" rows="9" cols="60">
</textarea>
</td></tr>
<tr><td align="center" colspan="2">
<input type='hidden' name='recipient' value=',
, , '>
<input type="hidden" name="redirect" value="http://foo.com/thanks.html">
<input type="hidden" name="required" value="email,message">
<input type="hidden" name="env_report" value="REMOTE_HOST, HTTP_USER_AGENT">
<input type="hidden" name="print_config" value="email,subject">
<input type="hidden" name="print_blank_fields" value="1">
<input type="hidden" name="title" value="Email Confirmation">
<input type="hidden" name="return_link_url"
value="http://foo.com/thanks.html">
<input type="hidden" name="return_link_title" value="">
<input type="hidden" name="background" value="">
<input type="hidden" name="bgcolor" value="">
<input type="hidden" name="text_color" value="">
<input type="hidden" name="link_color" value="">
<input type="hidden" name="vlink_color" value="">
<input type="hidden" name="alink_color" value="">
<br><INPUT class="submit" type=submit value="Send Message">
<input type="reset" value="Reset"></form>
</p>
</div>
</p>
</td></tr>
</table></h6></p>
</SELECT></FORM>
</body>
</html>


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Affecting a dynamically created drop down from another dynamically created drop down. msimmons ASP .Net 0 07-16-2009 03:17 PM
retrive preselected value in second drop down list from the first drop down list weiwei ASP .Net 0 01-05-2007 07:29 PM
New to .NET, can I have one drop down box control the data of another drop down box using a database? SirPoonga ASP .Net 2 01-07-2005 10:44 PM
Dynamic populate drop down menu Greg Scharlemann Javascript 4 12-12-2003 09:39 PM
dynamically populate drop down menu option value problem julian ASP General 3 11-05-2003 09:50 PM



Advertisments
 



1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57