FG1
09-30-2003, 07:30 AM
It would appear that using Javascript in IE6 with ASP you can't call submit() from a link's OnClick. Is this correct, or am I missing something.
As short sample follows. The file should be called Demo1.asp
FG
<html>
<head>
<SCRIPT LANGUAGE="JavaScript">
<!-- // Activate cloak
function fTest(){
document.f.submit();
}
// Deactivate cloak -->
</SCRIPT>
</head>
<body>
<form name="f" action="Demo1.asp" method="post">
<input type="text" name="frmSubmitCount" value="<% =request.form("frmSubmitCount") + 1 %>" ><br />
<a class="DryLnk" href="javascript:void(0)" onClick="Javascript:fTest()" >Doesn't Work</a><br />
<a class="DryLnk" href="Javascript:fTest()" >Works</a>
</form>
</body>
</html>
As short sample follows. The file should be called Demo1.asp
FG
<html>
<head>
<SCRIPT LANGUAGE="JavaScript">
<!-- // Activate cloak
function fTest(){
document.f.submit();
}
// Deactivate cloak -->
</SCRIPT>
</head>
<body>
<form name="f" action="Demo1.asp" method="post">
<input type="text" name="frmSubmitCount" value="<% =request.form("frmSubmitCount") + 1 %>" ><br />
<a class="DryLnk" href="javascript:void(0)" onClick="Javascript:fTest()" >Doesn't Work</a><br />
<a class="DryLnk" href="Javascript:fTest()" >Works</a>
</form>
</body>
</html>