Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Dreamweaver (all versions) section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old February 27th, 2006, 03:06 AM
Friend of Wrox
 
Join Date: May 2005
Location: tehran, tehran, Iran.
Posts: 201
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via Yahoo to hastikeyvan
Default dependent select menu

Hello all
I have 3 dependent menus(that 2 of them are working)but for the third one I conditions are different:
1-when we select an item in first select, in the second select will show the values that are related to first select
2-when we select an item in second select,if we select some special values in the third select will show the values that are related to second select:
for example:we select meadle east in first select
then it will show the countries of meadle east and when we select iran in second swelect(jus when we select iran) it will show some cities of iran in the third select
the code for third select is as below:

<select name="country">
<option value="iran">Iran</option>
....
</select>
<select name="city">
<option value="tehran>Tehran</option>
...
</select>
<script for="country" language="VBScript" event="onchange">
if document.forms[form1].country.options[country.selectedIndex]='Iran' then
document.form1.city.options[1]=new option('tehran','tehran')
... end if
                    </script>
can we write the code like this?whould some one help me please.thank you

  #2 (permalink)  
Old February 27th, 2006, 04:34 AM
Imar's Avatar
Wrox Author
Points: 70,322, Level: 100
Points: 70,322, Level: 100 Points: 70,322, Level: 100 Points: 70,322, Level: 100
Activity: 0%
Activity: 0% Activity: 0% Activity: 0%
 
Join Date: Jun 2003
Location: Utrecht, Netherlands.
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi hastikeyvan,

Are you trying to do this client side? If so, you may be better off posting this in the JavaScript forum.

If you want to do this with server side code, you could post this in one of the ASP forums.

This is not something that Dreamweaver offers out of the box, so you'll need to look into client or server side programming languages.

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.


Similar Threads
Thread Thread Starter Forum Replies Last Post
Chain Select Menu with ASP chame Classic ASP Basics 1 May 1st, 2008 06:18 PM
dependent select menu hastikeyvan Classic ASP Professional 3 November 10th, 2006 01:46 PM
Populate Select Menu from MySQL Database joviyach PHP Databases 4 June 24th, 2006 09:38 PM
disabling drop-down menu (select) crmpicco Javascript How-To 2 March 1st, 2005 07:08 AM
Select Menu Multiple Selections phungleon HTML Code Clinic 2 July 20th, 2004 12:25 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.