asp中文數(shù)字驗(yàn)證碼
更新時間:2008年11月03日 11:26:52 作者:
大寫數(shù)字驗(yàn)證碼的實(shí)現(xiàn)方法
復(fù)制代碼 代碼如下:
<form method="post" name=myform>
姓 名:<input type="text" name="name" value=""><br>
學(xué) 號:<input type="text" name="num" value=""><br>
。。。:<input type="text" name="aaa" value=""><br>
。。。:<input type="text" name="bbb" value=""><br>
驗(yàn)證碼:<img src="vcode/c.asp" onclick="this.src=this.src" title="點(diǎn)擊圖片可以更改驗(yàn)證碼" height="13" width="52">
<input type="text" size="5" name="C" autocomplete="off" style="ime-mode:disabled;" value="">
<input type="submit" value="提交">
</form>
asp代碼:
復(fù)制代碼 代碼如下:
<%
c = Request.form("c")
'如果可以輸入小寫的數(shù)字,請把下面三行注釋掉
for ii = 0 to 9
c = Replace(c,Cstr(ii),"")
next
c = Replace(c,"零","0")
c = Replace(c,"一","1")
c = Replace(c,"二","2")
c = Replace(c,"三","3")
c = Replace(c,"四","4")
c = Replace(c,"五","5")
c = Replace(c,"六","6")
c = Replace(c,"七","7")
c = Replace(c,"八","8")
c = Replace(c,"九","9")
if Cstr(c) <> Cstr(Session("validateCode")) then
Response.write ("驗(yàn)證碼不正確")
Response.end
end if
%>
相關(guān)文章
asp下實(shí)現(xiàn)IP限制函數(shù)代碼
asp下實(shí)現(xiàn)IP限制函數(shù)代碼...2007-11-11ASP 連接Access數(shù)據(jù)庫的登陸系統(tǒng)
這篇文章主要為大家詳細(xì)介紹了ASP 連接Access數(shù)據(jù)庫的登陸系統(tǒng),感興趣的小伙伴們可以參考一下2016-07-07