checklogined.asp

来自「这个也是一个功能强大的企业整站的ASP源代码」· ASP 代码 · 共 25 行

ASP
25
字号
<% 
'得到当前页面的地址
if session("LoginUser")="" then 
   response.Cookies("GetUrl")=GetUrl()
   response.Redirect("/Member/Login.asp")
   response.end
end if


Function GetUrl() 
  On Error Resume Next 
  Dim strTemp 
  If LCase(Request.ServerVariables("HTTPS")) = "off" Then 
    strTemp = "http://" 
  Else 
    strTemp = "https://" 
  End If 
  strTemp = strTemp & Request.ServerVariables("SERVER_NAME") 
  If Request.ServerVariables("SERVER_PORT") <> 80 Then strTemp = strTemp & ":" & Request.ServerVariables("SERVER_PORT") 
  strTemp = strTemp & Request.ServerVariables("URL") 
  If Trim(Request.QueryString) <> "" Then strTemp = strTemp & "?" & Trim(Request.QueryString) 
    GetUrl = strTemp 
End Function 
%> 

⌨️ 快捷键说明

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