Click to See Complete Forum and Search --> : Can anyone help me modify a script ?


steve501
05-06-2003, 08:43 PM
Hi there,

I have implemented a javascript on a page which automatically changes the values of a drop down box.

See http://www.downunderpants.com/oz/bonds/bn38J1.html

You will find when you select a "color" it automatically calls the "sizes" for that color which is in the script within the <head> tags.

The label name for the "color" list/menu is product_options[0] and the label name for the size list/menu is Team.

What I need to do is amend the label name Team to product_options[1] so my database will recognise the field label but am having trouble doing this with the script.

Alternatively some advice that has come through is

(When the form is sumbitted, can you use Javascript to copy the value of "team"
to product_options[1] ? This would allow you to do your updating while on that
page, then the value is transferred at the end.

eg.

You would just need a hidden field for product_options[1], then assign the value
"onSubmit")

Can anyone elaborate on this, I'm at a loss ?

Tnks / Steve