Hello friends,
I am trying to call a function from the onclick of an <option> tag. I just have a simple alert message within the function. The function doesn't get called. I have posted the code below:
<HEAD>
<SCRIPT type="text/javascript">
function func_1() {
alert('test');
}</SCRIPT>
</HEAD>
<body>
<SELECT size="10" name="Reports">
<OPTION value="unapproved">Unapproved</OPTION>
<OPTION value="history" onclick="func_1();">History</OPTION>
</SELECT>
</body>
Thanks,
Salil
I am trying to call a function from the onclick of an <option> tag. I just have a simple alert message within the function. The function doesn't get called. I have posted the code below:
<HEAD>
<SCRIPT type="text/javascript">
function func_1() {
alert('test');
}</SCRIPT>
</HEAD>
<body>
<SELECT size="10" name="Reports">
<OPTION value="unapproved">Unapproved</OPTION>
<OPTION value="history" onclick="func_1();">History</OPTION>
</SELECT>
</body>
Thanks,
Salil