回复 2楼 aspic
aspic老师,您好!您就提提醒吧!您就帮帮我吧,下面是用DW生成的限制页面访问的代码,帮我看看吧,我知道您很不赞成用DW生成的,我会慢慢学的呀,眼下请您帮我渡过这一关吧......跪求!!!谢谢!
这是对后台管理页面限制代码:
<%
' *** Restrict Access To Page: Grant or deny access to this page
MM_authorizedUsers="管理员,超级管理员"
MM_authFailedURL="../admin/ts.asp"
MM_grantAccess=false
If Session("MM_Username") <> "" Then
If (false Or CStr(Session("MM_UserAuthorization"))="") Or _
(InStr(1,MM_authorizedUsers,Session("MM_UserAuthorization"))>=1) Then
MM_grantAccess = true
End If
End If
If Not MM_grantAccess Then
MM_qsChar = "?"
If (InStr(1,MM_authFailedURL,"?") >= 1) Then MM_qsChar = "&"
MM_referrer = Request.ServerVariables("URL")
if (Len(Request.QueryString()) > 0) Then MM_referrer = MM_referrer & "?" & Request.QueryString()
MM_authFailedURL = MM_authFailedURL & MM_qsChar & "accessdenied=" & Server.URLEncode(MM_referrer)
Response.Redirect(MM_authFailedURL)
End If
%>