一句ASP语句,请大家帮我看下,...

来源:百度知道 编辑:UC知道 时间:2024/05/14 04:19:06
请问各位大虾,,
...
if Instr(LCase(Application(\"onlinelist\")),LCase(username&\" \"))=0
then
...
上面这个ASP语句是什么意思呀`?

语法上有问题啊。那几个\好像不应该出现。
看上去应该是在聊天室中检测Application全局对象中的onlinelist(在线名单)中是否有username这个变量对应的用户。
lcase是将字符串格式化成小写。
instr(str1,str2)返回在str1字符串中str2所在的位置。如果不存在返回0,否则返回大于0的值。(0为false,非0为TRUE)
希望对你有帮助

我是学这个的,不过我还不会,呵呵

if语句 后面是SQL更新语句!还有 if 和 then 要写在一行

LCase 将字符串转换为小写
Instr(A,B) 判断A中B出现的位置,如果没有则返回0
LCase(Application(\"onlinelist\"))
将Application(\"onlinelist\")中的字符转换为小写
if Instr(LCase(Application(\"onlinelist\")),LCase(username&\" \"))=0
假如LCase(Application(\"onlinelist\"))中没有出现LCase(username&\" \")