提交表单后,怎么设置弹窗提示?
我是asp新手,大家不要笑我,如下代码,代码是没有问题的,只是提交表单成功后不知道怎么设置弹窗提示"已设置成功"?
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>用戶權限管理 UserRightsManagement</title>
<!--#include file="../Connections/conn.asp" -->
<!--#include file="../Connections/connopen.asp" -->
<%
i = 0
set rst=Server.CreateObject("adodb.recordset")
sql="select * from e_users where u_id='"&Trim(Request.QueryString("u_id"))&"'"
rst.open sql,conn,1,1
If (CStr(Request("insert")) = "form1") Then
u_id=Trim(Request.QueryString("u_id"))
set rst3=server.CreateObject("adodb.recordset")
sql3="select * from e_item "
rst3.open sql3,conn,1,1
do while not rst3.eof
i_id=rst3("i_id")
p_add=request("p_add"&i_id)
if p_add="" then p_add=0 else p_add=1 end if
p_edit=request("p_edit"&i_id)
if p_edit="" then p_edit=0 else p_edit=1 end if
p_invalid=request("p_invalid"&i_id)
if p_invalid="" then p_invalid=0 else p_invalid=1 end if
p_view=request("p_view"&i_id)
if p_view="" then p_view=0 else p_view=1 end if
set rst4=server.CreateObject("adodb.recordset")
sql4="select * from e_itempermissions where u_id="&u_id&" and i_id="&i_id&" "
rst4.open sql4,conn,1,1
if rst4.recordcount>0 then
sql="update e_itempermissions set p_add="&p_add&",p_edit="&p_edit&" ,p_invalid="&p_invalid&" ,p_view="& p_view&" where u_id="&u_id&" and i_id="&i_id&" "
' response.Write(sql)
' response.end
conn.execute sql
else
sql="insert into e_itempermissions (u_id,i_id,p_add,p_edit,p_invalid,p_view) values ("&u_id&","&i_id&","&p_add&","&p_edit&","&p_invalid&","&p_view&")"
' response.Write(sql)
'response.end
conn.execute sql
end if
Response.Flush
rst3.movenext
loop
rst3.close
set rst3=nothing
rst4.close
set rst4=nothing
end if
%>
</head>
<body>
<form id="form1" name="form1" method="post" action="<%=MM_editAction%>">
<table width="528" height="304" border="1" cellpadding="0" cellspacing="0">
<tr>
<td colspan="4">用戶權限管理</td>
</tr>
<tr>
<td width="60">姓名</td>
<td width="176"><label for="u_name"></label>
<input name="u_name" type="text" id="u_name" value="<%=rst("u_name")%>"/></td>
<td width="86">成本中心</td>
<td width="196"><input type="text" name="Costcenter" id="Costcenter" value="<%=rst("Costcenter")%>"/></td>
</tr>
<%
set rst1=Server.createObject("adodb.recordset")
sql1="select a.*,isnull(P_add,0) P_add,isnull(p_edit,0) p_edit ,isnull(P_view,0) P_view," & _
" isnull(p_invalid,0) p_invalid ,b.p_id from e_item a left join e_itempermissions b " & _
" on a.i_id=b.i_id and b.u_id='"&Trim(Request.QueryString("u_id"))&"' "
rst1.open sql1,conn,1,1
i=1
do while not rst1.eof
%>
<tr>
<td><%=rst1("i_item")%>
</td>
<td colspan="3">
<input <% if ( CStr(rst1("p_add")) = CStr("1") ) Then Response.Write("checked=""checked""") : Response.Write("") %> name="p_add<%=rst1("i_id")%>" type="checkbox" id="p_add<%=rst1("i_id")%>" value="1" />
新增
<input <% if (cstr(rst1("p_edit"))=CStr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_edit<%=rst1("i_id")%>" type="checkbox" id="p_edit<%=rst1("i_id")%>" value="1" />
修改
<input <% if (CStr(rst1("p_invalid"))=Cstr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_invalid<%=rst1("i_id")%>" type="checkbox" id="p_invalid<%=rst1("i_id")%>" value="1" />
作廢
<input <% if (CStr(rst1("p_view"))=CStr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_view<%=rst1("i_id")%>" type="checkbox" id="p_view<%=rst1("i_id")%>" value="1" />
查詢
</td>
</tr>
<% i=i+1
Response.Flush
rst1.movenext
loop
'end if
%>
<tr>
<td colspan="4"><input type="submit" name="button" id="button" value="提交" />
<input type="reset" name="button2" id="button2" value="重置" />
<input name="zs" type="hidden" id="zs" value="<%=i-1%>" /></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
<input type="hidden" name="insert" value="form1" />
</form>
</body>
</html>
<%
rst.close
set rst=nothing
%>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>用戶權限管理 UserRightsManagement</title>
<!--#include file="../Connections/conn.asp" -->
<!--#include file="../Connections/connopen.asp" -->
<%
i = 0
set rst=Server.CreateObject("adodb.recordset")
sql="select * from e_users where u_id='"&Trim(Request.QueryString("u_id"))&"'"
rst.open sql,conn,1,1
If (CStr(Request("insert")) = "form1") Then
u_id=Trim(Request.QueryString("u_id"))
set rst3=server.CreateObject("adodb.recordset")
sql3="select * from e_item "
rst3.open sql3,conn,1,1
do while not rst3.eof
i_id=rst3("i_id")
p_add=request("p_add"&i_id)
if p_add="" then p_add=0 else p_add=1 end if
p_edit=request("p_edit"&i_id)
if p_edit="" then p_edit=0 else p_edit=1 end if
p_invalid=request("p_invalid"&i_id)
if p_invalid="" then p_invalid=0 else p_invalid=1 end if
p_view=request("p_view"&i_id)
if p_view="" then p_view=0 else p_view=1 end if
set rst4=server.CreateObject("adodb.recordset")
sql4="select * from e_itempermissions where u_id="&u_id&" and i_id="&i_id&" "
rst4.open sql4,conn,1,1
if rst4.recordcount>0 then
sql="update e_itempermissions set p_add="&p_add&",p_edit="&p_edit&" ,p_invalid="&p_invalid&" ,p_view="& p_view&" where u_id="&u_id&" and i_id="&i_id&" "
' response.Write(sql)
' response.end
conn.execute sql
else
sql="insert into e_itempermissions (u_id,i_id,p_add,p_edit,p_invalid,p_view) values ("&u_id&","&i_id&","&p_add&","&p_edit&","&p_invalid&","&p_view&")"
' response.Write(sql)
'response.end
conn.execute sql
end if
Response.Flush
rst3.movenext
loop
rst3.close
set rst3=nothing
rst4.close
set rst4=nothing
end if
%>
</head>
<body>
<form id="form1" name="form1" method="post" action="<%=MM_editAction%>">
<table width="528" height="304" border="1" cellpadding="0" cellspacing="0">
<tr>
<td colspan="4">用戶權限管理</td>
</tr>
<tr>
<td width="60">姓名</td>
<td width="176"><label for="u_name"></label>
<input name="u_name" type="text" id="u_name" value="<%=rst("u_name")%>"/></td>
<td width="86">成本中心</td>
<td width="196"><input type="text" name="Costcenter" id="Costcenter" value="<%=rst("Costcenter")%>"/></td>
</tr>
<%
set rst1=Server.createObject("adodb.recordset")
sql1="select a.*,isnull(P_add,0) P_add,isnull(p_edit,0) p_edit ,isnull(P_view,0) P_view," & _
" isnull(p_invalid,0) p_invalid ,b.p_id from e_item a left join e_itempermissions b " & _
" on a.i_id=b.i_id and b.u_id='"&Trim(Request.QueryString("u_id"))&"' "
rst1.open sql1,conn,1,1
i=1
do while not rst1.eof
%>
<tr>
<td><%=rst1("i_item")%>
</td>
<td colspan="3">
<input <% if ( CStr(rst1("p_add")) = CStr("1") ) Then Response.Write("checked=""checked""") : Response.Write("") %> name="p_add<%=rst1("i_id")%>" type="checkbox" id="p_add<%=rst1("i_id")%>" value="1" />
新增
<input <% if (cstr(rst1("p_edit"))=CStr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_edit<%=rst1("i_id")%>" type="checkbox" id="p_edit<%=rst1("i_id")%>" value="1" />
修改
<input <% if (CStr(rst1("p_invalid"))=Cstr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_invalid<%=rst1("i_id")%>" type="checkbox" id="p_invalid<%=rst1("i_id")%>" value="1" />
作廢
<input <% if (CStr(rst1("p_view"))=CStr("1")) then response.write("checked=""checked""") : response.write("") %> name="p_view<%=rst1("i_id")%>" type="checkbox" id="p_view<%=rst1("i_id")%>" value="1" />
查詢
</td>
</tr>
<% i=i+1
Response.Flush
rst1.movenext
loop
'end if
%>
<tr>
<td colspan="4"><input type="submit" name="button" id="button" value="提交" />
<input type="reset" name="button2" id="button2" value="重置" />
<input name="zs" type="hidden" id="zs" value="<%=i-1%>" /></td>
</tr>
<tr>
<td> </td>
<td> </td>
<td> </td>
<td> </td>
</tr>
</table>
<input type="hidden" name="insert" value="form1" />
</form>
</body>
</html>
<%
rst.close
set rst=nothing
%>
...全文
基于禾赛32线雷达和Xsens MTi-G-710 组合导航模块,松灵Scout mini 底盘实现 Cartographer 3D 建图过程 地下车库 Cartongrapher 3D建图 阅读详情
相关推荐
基于JS+HTML实现弹窗提示是否确认提交功能
需求:当点击input按钮时候,弹出确认框,确认后提交到指定url,效果如下 分析:这里面要,引入三个库文件,如下是下载地址 layui样式文件:https://layer.layui.com/ layer弹窗组件:https://www.layui.com/ jquery代码库:http://www.jq22.com/ 代码:下载后放入响应的项目目录,最后代码如下 <!DOCTYPE html> <html> <head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, i
对django layer弹窗组件的使用详解
今天小编就为大家分享一篇对django layer弹窗组件的使用详解,具有很好的参考价值,希望对大家有所帮助。一起跟随小编过来看看吧
layui button 按钮弹出提示窗口,确定才进行的方法
今天小编就为大家分享一篇layui button 按钮弹出提示窗口,确定才进行的方法,具有很好的参考价值,希望对大家有所帮助。一起跟随小编过来看看吧
好用的漂亮提示框,js提示框
好用的漂亮提示框,比起系统自带的提示框要好看许多,大家可以尝试下
jquery实现弹窗表单填写提交
本资源是我个人修改完成的 功能是:点击按钮实现弹窗,弹窗中有表单,可以进行填写表单的内容并可进行提交!


