利用 IFrame 提交表单后回到本页
来源:互联网 发布:vga视频矩阵切换器调试 编辑:程序博客网 时间:2024/05/29 18:02
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=gb2312">
<title>无标题文档</title>
</head>
<body>
<form name="form1" method="post" action="" onSubmit="return check()" target="Hide">
<table width="95%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td width="27%" height="25" align="center">姓名:</td>
<td width="73%"><input type="text" name="username"></td>
</tr>
<tr>
<td height="25" align="center">Email:</td>
<td><input type="text" name="mail"></td>
</tr>
<tr>
<td height="25" align="center">电话:</td>
<td><input type="text" name="phone"></td>
</tr>
<tr>
<td height="25" align="center">留言:</td>
<td align="center"><textarea name="content" cols="20" rows="5"></textarea></td>
</tr>
<tr>
<td height="25" colspan="2" align="center"><input type="submit" name="Submit" value="提交">
<input type="reset" name="Submit2" value="重置"></td>
</tr>
</table>
</form><%
if request("username")<>"" then
set rs=server.CreateObject("adodb.recordset")
sql="select * from message where id is null"
rs.open sql,conn,1,3
rs.addnew
rs("username")=request("username")
rs("mail")=request("mail")
rs("phone")=request("phone")
rs("content")=request("content")
rs.update
if err.number<>0 then
err.clear
response.Write("<script>alert('您填写的信息提交失败');window.parent.window.location.reload();</script>")
else
response.Write("<script>alert('您填写的信息提交成功');window.parent.window.location.reload();</script>")
end if
end if
%>
<script>
<iframe name="Hide" style="display:none "></iframe>
</body>
</html>
或者还可以利用
location.href(request.serverViarable("http_referer"))
可以回到本页
- 利用 IFrame 提交表单后回到本页
- dojo090之利用iframe提交表单数据
- 第一次页面正常,提交后验证失败,重新回到表单页乱码
- jquery ajaxfileupload利用iframe表单提交实现ajax文件上传
- 利用iframe实现提交表单是页面部分刷新
- 利用iframe实现表单的无刷新提交
- 利用iframe实现表单的无刷新提交
- 111 js iframe表单提交后自动关闭 &
- 获取iFrame框架中Form表单提交后的结果
- 表单提交后,还是停留在本页面的问题
- javascript onsubmit本页面验证form表单后提交
- Firefox下打开wap站的表单,第一次页面正常,提交后验证失败,重新回到表单页乱码是什么原因造成的
- iframe 无刷新提交表单
- iframe无刷新提交表单
- 在iframe里面提交表单
- 提交更新数据后刷新本页
- 利用Ajax提交表单
- 利用javascript提交表单
- 八皇后问题
- 2007-7-16
- 监控软件的开发模式探讨
- 2007.7.16及时分析!
- Oracle:pl/sql 异常处理
- 利用 IFrame 提交表单后回到本页
- 游标
- 项目管理手记(四) DRP项目中软件系统架构的比较
- 工作中解决的小问题
- MSSQL事务(资料)
- 点评应用服务器之江湖兵器谱大排名 (转)
- 就会报Unhandled exception at 0x1000a0ce (Libnet.dll) in tcp1.exe: 0xC0000005: Access violation reading location 0xfffffe64.错误。 请问为什
- ZIP書庫の作成、閲覧、展開を行う
- jBPM websale代码学习: home.jsp(启动流程)