<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<title> New Document </title>
<meta name="Generator" content="EditPlus">
<meta name="Author" content="">
<meta name="Keywords" content="">
<meta name="Description" content="">
<script type="text/javascript">
function hello(){
tanchu();
$("submitForm").submit();
}
function tanchu(){
alert("自动提交表单啊");
$("submitForm").submit();
}
</script>
</head>
<body>
<form action="www.baidu.com" method = "post" id = "submitForm" >
<table>
<tr>
<td>
<font size="3" color="red" >
自动提交表单
</font>
</td>
</tr>
</table>
</form>
<script text="javascript">
hello();
</script>
</body>
</html>
现在我写的html是不好使的,我只是想通过这个例子,告诉大家,如果想自动提交表单的话,要在<body></body>里的form后面加上你的javascript就可以