I have just added some Javascripts to keep my <div> elements hidden until the user chooses a value under <select><option>...This way I do not have to submit the form and then redisplay to display the choosen element.
However. When the new form is then submitted the page is redisplayed with the results and the div element is again hidden.
Initially all <div> fields are to be hidden, but I want to show the last choosen filed after a form submit(technically when the form reloads again the javascript treats it as an initial load and all is hidden).
I cannot set the divFieldID.className="show"; before a javascript method is called in a form <select onchange="myFunction();">.
I have a
JSP variable I can access to find out it the user has choosen a form in the <select><option>...
Can I fix this with Javascript, or do I have to abandon it and revert to my old JSP if-else with
alot if submit