68
rated 0 times
[
71]
[
3]
/ answers: 1 / hits: 8986
/ 7 Years ago, sat, january 28, 2017, 12:00:00
I have two dropdown menus as follows:
<form id=dynamicForm>
<select id=A>
</select>
<select id=B>
</select>
</form>
And I have a dictionary object where the keys are the options for A
and the values, B
are arrays corresponding to each element in A
, as follows:
var diction = {
A1: [B1, B2, B3],
A2: [B4, B5, B6]
}
How can I dynamically populate the menu B based on what the user selects in menu A?
More From » jquery