T
The Natural Philosopher
Consider the function:
function edit_new()
{
document.getElementsByName("order_id")[0].value="0";
alert(document.getElementsByName("order_id")[0].value);
document.forms[0].submit();
}
In conjunction with the code
<SELECT name="order_id" style="width:150px">
<OPTION value="any" selected>Any</Option>
<OPTION value="1" >000001</OPTION>
<OPTION value="2" >000002</OPTION>
<OPTION value="3" >000003</OPTION>
</SELECT>
When it is invoked, it prints the contents of what its supposed to all
right.
But it is never 0!!!
Its 1,2,3 or 'any' depending what I select.
What fundamental errors am I making?
Its worked everywhere else!!
function edit_new()
{
document.getElementsByName("order_id")[0].value="0";
alert(document.getElementsByName("order_id")[0].value);
document.forms[0].submit();
}
In conjunction with the code
<SELECT name="order_id" style="width:150px">
<OPTION value="any" selected>Any</Option>
<OPTION value="1" >000001</OPTION>
<OPTION value="2" >000002</OPTION>
<OPTION value="3" >000003</OPTION>
</SELECT>
When it is invoked, it prints the contents of what its supposed to all
right.
But it is never 0!!!
Its 1,2,3 or 'any' depending what I select.
What fundamental errors am I making?
Its worked everywhere else!!