close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Multiple dropdown menus - Parent, Child, Grandchild

Thread began 2/05/2010 2:51 pm by reiger399941 | Last modified 2/11/2010 3:22 pm by Eric Mittman | 6783 views | 5 replies |

reiger399941

Multiple dropdown menus - Parent, Child, Grandchild

I'm trying to setup multiple dependent dropdown menus... in this case Continent, Country, State, City, etc. Using the 'Getting Started' documentation I have the Continent and Country menus working just fine, but when I go through the procedure again to setup the State menu the dynamic array (rsCountries) is overwritten by the dynamic array (rsStates). So I have the Parent and Child working fine... it adding the Grandchild that I'm struggling with. Can someone explain how to setup the Grandchild menu?

Much appreciated,
Patrick

Sign in to reply to this post

Eric Mittman

There is not a limit to the dynamic arrays, you can have two of them on the page at once without issue. Please describe in detail the steps you are taking to add your dynamic arrays to the page so we can determine if there is an error some where.

Sign in to reply to this post

reiger399941

Unless I'm missing something, I believe I'm following the "Getting Started" guide to the letter.

1. First I create 3 recordsets: rsContinents, rsCountries, and rsStates.

2. Next I set add the 3 menus to the page: Continent, Country, and State and make the Continent menu dynamic by tying it to the rsContinents recordset.

3. I then create the dynamic array "Create Dynamic Array (rsCountries)". Then I select the Continent menu and populate it from array. At this point I have a working Continent and Country menu.

4. I then repeat #3 above except Country is the parent and State is the child. I create the dynamic array "Create Dynamic Array (rsStates)". Then I select the Country menu and populate it from array. Unfortunately, at this point the State menu does nothing. Not sure why.

Thanks,
Patrick

Sign in to reply to this post

Eric Mittman

Ok, so when you are creating the second dynamic array you are able to have both on the page at once correct?

If you have the create dynamic arrays and populate list from arrays on the page then that part should be ok. You may be experiencing a problem with the relationship of the countries to the states. How do you have this relationship defined in your db?

If you could post back with the three tables in an sql file I could check on it and do a test to help determine what the problem may be.

Sign in to reply to this post

reiger399941

Eric,

Yes, I am able to have both dynamic arrays on the page at once.

Please find files of interest attached.

Thanks for your help,
Patrick

Attached Files
dropdown menu issue.zip
Sign in to reply to this post

Eric Mittman

I did some testing on this and created a page like yours and was able to get it to work as expected. What I think is happening is that when you select the continent it is defaulting to the United States. Since the populate list from array is applied to the onChange of the county select list the states will not be selected unless a change is made to the country select list.

To account for this in your populate list from array behavior applied to the continent select list update it and in the Target list options enter 1 for the leave top. This will make it so the user must select either one of the choices and when they do the states list will populate automatically.

On your page if I choose Canada it will populate with the Canadian states, if I then select USA it will populate with the US states.

Sign in to reply to this post

dvan_zelst

Hi all,

I tried the dynamic dropdown with 3 list menu's and it works, however when you populate your choices in all three list menus and change the first list/menu selection it will not update the third list/menu. The third updates when a change is made in the second list/menu. I think this should not be or am i doing something wrong?

I think maybe this is the reason why it is stated that dynamic dropdown is made to work with two list/menu items only, or not?

Thanks

Sign in to reply to this post

Jason ByrnesWebAssist

the third drop down wont be effected by the first dropdown, unless you add another onchange event to the first dropdown to change the third dropdown.

add another popualte list from array behavior to the onchaneg event to the first dropdopwn to manage the third one.

Sign in to reply to this post

dvan_zelst

Dear Jason,

Will this not result in the third dropdown being populated without selecting anything in the second dropdown? If so then i think it is also not correct.

I have seen multiple dropdowns where the second and third jump back to their default "choose" value when the first dropdown is changed but i have to state they used AJAX technology to update all dropdowns. So i wonder if it is possible to create the same effect with Dynamic Dropdowns.

I will give your suggestion a try later to see what happens.

Thanks.

Sign in to reply to this post

Jason ByrnesWebAssist

you could use the set selected in list behavior on the onchange event of the first list to set the third list to the default empty value.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...