Forum Moderators: open

Message Too Old, No Replies

Repopulating form fields based on user interaction.

Need some help with my logic

         

Reflection

11:21 pm on Jun 3, 2003 (gmt 0)

10+ Year Member



I need some help on how to approach this problem as I appear to be going in circles :) I will try and explain myself without all the unnecessary specifics...

I have 3 form fields as follows:

A select drop down with integer values.(I will refer to it as A)
A select drop down with a list of values which are populated from a javascript array.(Reffered to as B)
A text field which will display a value according to what is selected in the first 2 drop downs

Now the problem I have is that the values in B sometimes need to be changed based on what is chosen in A.

Ideally the user would select a value in A, B would then be populated. However after B is populated they could go back and change A. So my main problem is how to populate B and then how to respond if the user goes back and make changes to A.

I will also note that this is a small part of a larger form.

Thanks for any suggestions.

le_gber

8:41 am on Jun 4, 2003 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Hello Reflection,

I think I found what you needed have a look here:

[google.com...]

have a look at the third site as I think answers the questions you asked.

Basically it uses javascript and onChange events

Hope this helps (and that the URL is ok).

Leo

Reflection

6:22 pm on Jun 4, 2003 (gmt 0)

10+ Year Member



Thanks le_gber, that pointed me in the right direction.

I think I have it figured out now... wish I had used that combination of search terms :)