参考红色代码
Dim fl As String = "d:\Web\" & e.path
Dim wb As New weui
If filesys.FileExists(fl)
Dim idx As Integer = fl.LastIndexOf(".")
Dim ext As String = fl.SubString(idx)
Select Case ext
Case ".jpg",".gif",".png",".bmp",".wmf",".js",".css" ,".html",".htm",".zip",".rar",".mp4",".mp3",".txt"
e.WriteFile(fl)
Return '这里必须返回
End Select
End If
Select Case e.Path
Case "AllCurricularTaxonomy.htm",""
Functions.Execute("AllCurricularTaxonomy",e)
return
Case "CurricularTaxonomy.htm"
Functions.Execute("CurricularTaxonomy",e)
return
End Select
'身份验证
Dim Verified As Boolean '用于标记用户是否通过了身份验证
Dim UserName As String = e.Cookies("username") '从cookie中获取用户名
Dim Password As String = e.Cookies("password") '从cookie中获取用户密码
If e.Path = "UserLogin.htm" '如果是通过登录页面访问,从PostValues即可中提取用户名和密码