用户名已经存在,注册的时候还被判断可以注册如何修复-动易CMS教程

来源:模板无忧 作者:tao1112 更新时间:2007-08-27 点击:

问题: 新会员注册时,用已存在的会员名注册新用户时仍然判定可以申请

图片点击可在新窗口打开查看此主题相关图片如下:


图片点击可在新窗口打开查看

等到所有信息都正确填写后,继续下一步注提交注册信息时,出现下图:

图片点击可在新窗口打开查看此主题相关图片如下:


图片点击可在新窗口打开查看

解决方法: 以下两种方法任选一种

1.打开inc目录下的checklist.asp文件

Sub usercheck()
Dim rtext, UserNameLimit, UserNameMax, UserName_RegDisabled
If InStr(iname, \"=\") > 0 Or InStr(iname, \"%\") > 0 Or InStr(iname, Chr(32)) > 0 Or InStr(iname, \"?\") > 0 Or InStr(iname, \"&\") > 0 Or InStr(iname, \";\") > 0 Or InStr(iname, \",\") > 0 Or InStr(iname, \"'\") > 0 Or InStr(iname, \".\") > 0 Or InStr(iname, Chr(34)) > 0 Or InStr(iname, Chr(9)) > 0 Or InStr(iname, \"\") > 0 Or InStr(iname, \"$\") > 0 Or InStr(iname, \"*\") Or InStr(iname, \"|\") Or InStr(iname, \"\"\"\") > 0 Then
Response.write \"2\" '含有非法字符
Else
If strLength(iname) > 4 Then
If LCase(Right(iname, 4)) = \".asp\" Or LCase(Right(iname, 4)) = \".asa\" Or LCase(Right(iname, 4)) = \".cer\" Or LCase(Right(iname, 4)) = \".cdx\" Then
Response.write \"2\" '含有非法字符
End If
Else

Set rtext = Conn.Execute(\"select top 1 UserNameLimit,UserNameMax,UserName_RegDisabled from PE_Config\")
If Not (rtext.bof And rtext.EOF) Then
UserNameLimit = rtext(\"UserNameLimit\")
UserNameMax = rtext(\"UserNameMax\")
UserName_RegDisabled = rtext(\"UserName_RegDisabled\")
Else
UserNameLimit = 4
UserNameMax = 20
End If
rtext.Close

If strLength(iname) > 20 Or strLength(iname) < UserNameLimit Then
Response.write \"3\" '长度不合
Else
If FoundInArr(UserName_RegDisabled, iname, \"|\") = True Then
Response.write \"4\" '禁止注册
Else
Set rtext = Conn.Execute(\"select top 1 UserName from PE_User where UserName='\" & iname & \"'\")
If rtext.bof And rtext.EOF Then
Response.write \"0\"
Else
Response.write \"1\" '重复
End If

< Prev12 Next >
相关动易CMS教程:
最新评论:
loading.. 评论加载中....
发表评论:不能超过250字节,请自觉遵守互联网相关政策法规.
  • 昵称: 验证:

最新动易CMS教程