Retaining the value of drop down box after submission
<p>(In javascript) I have 8 drop down boxes one below the other on the same page. Each dropdown has options default, am and pm. The problem I'm facing is that, once the form is submitted, then on page reload, the selected drop down values are not retained.</p>

<p>Tried googling for possible solutions, but most of them involve usage of php code( Dont want to use phps in my code). Pls help.</p>

<p>Here's a portion of the code that I used.</p>

<pre><code>&lt;table caption="Clocks" ...&gt;
...
&lt;td&gt;
&lt;select id="time" name="time_ctr" onChange="setClks(ctr);"&gt;   //ctr ranges from 0 to 7
&lt;option&gt;&lt;/option&gt;
&lt;option value="a"&gt; AM&lt;/option&gt;
...(option for pm)..
&lt;/select&gt;
&lt;/td&gt;
&lt;script type='text/javascript&gt;
function setClks(ctr)
{
var newctr=ctr;
}
function getClks(){
var ctr1= newctr+1;
var selectedOp = new Array(8);

for (var i=0; i&lt; ctr1 ;i++)
{
var selectedOp[i]= document.getElementById("time_"+ctr).value;
}
return selectedOp;
}

&lt;...button label="Submit" OnClick="getClks();"..&gt;
</code></pre>
