将以下代码放到一个单独的页面checkcode.asp
<%
Option Explicit
Response.buffer=true
Call Com_CreatValidCode("validateCode")
Sub Com_CreatValidCode(pSN)
' 禁止缓存
Response.Expires = -9999
Response.AddHeader "Pragma","no-cache"
Response.AddHeader "cache-ctrol","no-cache"
Response.ContentType = "Image/BMP"
Randomize
Dim i, ii, iii
Const cOdds = 2 ' 杂点出现的机率
Const cAmount = ...
阅读全文分类:建站杂谈 | 阅读:7106 | 评论:0 | 更新:2013-7-24 12:01:43 By