I'm calling a function through <select onChange="funcname()"><option>. inside that function I got the selectedIndex value, but when I used that value as an index to get an array item which is declared in the <head> section and filled in the <body> I failed it always gets nothing.Does any one know why?
Software/Hardware used:
ASKED:
January 7, 2009 5:25 AM
UPDATED:
January 29, 2009 5:43 AM
I suspect that the scope of your array is limited to the <head> section, and it is invisible/nonexistent in the <body>. On a larger issue, I would suggest that you consider moving to JavaScript, rather than wasting your time learning a much weaker language that works in only one browser. At this point, your script would not have to be altered a great deal to be ported to JS.
Thanks for the concern you show here, as a matter of fact I’m strongly considering to use JaveScript or use it altogther with VBScript, in the following days I will be looking for some updated refrences, In the mean time my concern is to be able of designing dynamic web pages, again thanks for your cooperation.