userright_process.asp

来自「用ASP写的电子购物系统」· ASP 代码 · 共 39 行

ASP
39
字号
<%@ Language=VBScript %>
<!--#INCLUDE FILE = "include/manager.asp" -->
<%functionno=4%>
<!--#INCLUDE FILE="checkuser.asp" -->
<%
dim errorList 

cmdTemp.CommandText = "select * from privilege where groupname='" & request("groupname") & "'"

Set rs = Server.CreateObject("ADODB.Recordset")
rs.Open cmdTemp, , adOpenKeyset, adLockOptimistic


 if rs.RecordCount<>0 then
    cmdprod.CommandText = "delete from privilege  where groupname='"&request("groupname") & "'"
    cmdprod.Execute 
 end  if 

For I = 1 To Request.form("b").Count
   
  cmdprod.CommandText = "Insert into privilege(groupname,functionid)  values('" &request("groupname") &"' , "&Request.form("b")(i)&")" 
  cmdprod.Execute 
next

Response.Redirect "mgroup_list.asp"

if errorList.Count <> 0 then
%>
<HTML>
<HEAD>
<meta http-equiv="Content-Type" CONTENT="text/html"; charset="gb2312"></HEAD>
</HEAD>
<BODY>

<%end if  %>

</BODY>
</HTML>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?