<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Js的onload和js表单提交submit的demo示例</title>
<script language="javascript">
window.onload=function()
{
document.forms.registerform.submit();
}
</script>
</head>
<body>
<form id="registerform" name="register" method="post" action="www.baidu.com">
<label for="name"></label>
<input name="name" type="text" id="name" value="name" />
</form>
</body>
</html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Js的onload和js表单提交submit的demo示例</title>
<script language="javascript">
window.onload=function()
{
document.forms.registerform.submit();
}
</script>
</head>
<body>
<form id="registerform" name="register" method="post" action="www.baidu.com">
<label for="name"></label>
<input name="name" type="text" id="name" value="name" />
</form>
</body>
</html>
作者:jackxiang@向东博客 专注WEB应用 构架之美 --- 构架之美,在于尽态极妍 | 应用之美,在于药到病除
地址:https://jackxiang.com/post/3944/
版权所有。转载时必须以链接形式注明作者和原始出处及本声明!
评论列表