asp中LCase是什么意思!!急急!!!!!!

来源:百度知道 编辑:UC知道 时间:2024/07/13 03:55:35
if InStr(LCase(pwd),"'")<>0 or InStr(LCase(pwd),"or")<>0 then
response.write "<script language='javascript'>"
response.write "alert('密码不合法,请重新输入!');"
response.write "history.go(-1);"
response.write "</script>"
response.end
end if

请问这一段代码什么意思??

Lcase应该就是把pwd转成小写的意思, 如下:

LCase 函数

返回字符串的小写形式。

LCase(string)

string 参数是任意有效的字符串表达式。如果 string 参数中包含 Null,则返回 Null。
说明

仅大写字母转换成小写字母;所有小写字母和非字母字符保持不变。
下面的示例利用 LCase 函数把大写字母转换为小写字母:

Dim MyString
Dim LCaseString
MyString = "VBSCript"
LCaseString = LCase(MyString) ' LCaseString 包含 "vbscript"。

要求

这段代码就是检查密码中是否有单引号或"or”,如果有,就蹦出提示说:密码不合法,然后后退到上一页面