secretsquirrel
Programmer
Hi guys, I hope you can help me.
I've got a page with a Javascript function in it, which basically displays a hidden <DIV> when a certain value is selected from a dropdown list. This works with no problems.
The thing that's bugging me is the fact that I needed to use the same function on another page, so I pasted it into the new page and made sure all the associated elements were named correctly (the <DIV>, the <SELECT> and the <FORM> that the whole lot sits in), but when I run the page and change the selected item in the list, I get an error which is along the lines of "form.dropdownlist.selectedIndex is not an object".
The irritating thing is that it works perfectly in the original page. Has anyone else experienced anything like this, or do you have any suggestions.
Thanks in advance.
I've got a page with a Javascript function in it, which basically displays a hidden <DIV> when a certain value is selected from a dropdown list. This works with no problems.
The thing that's bugging me is the fact that I needed to use the same function on another page, so I pasted it into the new page and made sure all the associated elements were named correctly (the <DIV>, the <SELECT> and the <FORM> that the whole lot sits in), but when I run the page and change the selected item in the list, I get an error which is along the lines of "form.dropdownlist.selectedIndex is not an object".
The irritating thing is that it works perfectly in the original page. Has anyone else experienced anything like this, or do you have any suggestions.
Thanks in advance.