T
trfilmographer
Hi fellow web developers!
I have a little problem due to my lack of javascript / web developing
skills...
Basically I have a form embedded in a table. WHat I would like to do,
is have the form be submitted when I click on a href link. Currently
it appears that the page reloads - but nothing actually is submitted.
here is a demo code,,, is it something in the head?
<html>
<head>
<SCRIPT language="JavaScript">
function submitCode()
{
document.ApplyCode.submit();
}
</SCRIPT>
</head>
<body>
<table>
<tr>
<td>
<form action="thisPage.jsp" name="SubmitCode"
method="post">
Code:
<input type="text" name="Code" />
<!-- this is the line that doesnt work right -->
<a href="thisPage.jsp"
onClick="javascript: submitCode()">
Click Me
</a>
</form>
</td>
</tr>
</table>
</body>
</html>
I have a little problem due to my lack of javascript / web developing
skills...
Basically I have a form embedded in a table. WHat I would like to do,
is have the form be submitted when I click on a href link. Currently
it appears that the page reloads - but nothing actually is submitted.
here is a demo code,,, is it something in the head?
<html>
<head>
<SCRIPT language="JavaScript">
function submitCode()
{
document.ApplyCode.submit();
}
</SCRIPT>
</head>
<body>
<table>
<tr>
<td>
<form action="thisPage.jsp" name="SubmitCode"
method="post">
Code:
<input type="text" name="Code" />
<!-- this is the line that doesnt work right -->
<a href="thisPage.jsp"
onClick="javascript: submitCode()">
Click Me
</a>
</form>
</td>
</tr>
</table>
</body>
</html>