首 页 教育新闻课件中心论文中心教学教案试题中心语文专题综合下载技术教程公务员  
设为首页
加入收藏
联系我们
您当前的位置:中国教育资源网 -> 技术教程 -> 网站建设 -> 源码精华 -> 技术内容 退出登录 用户管理

VerifyCode(asp),gif验证码生成技术源码精华教程

论文作者:佚名  论文来源:不详  论文发布时间:2006-6-20 2:40:48  论文发布人:chjchjchj

减小字体 增大字体

<%
'--------------------------------------
'Fly38.com - VerifyCode Class
' gif 验证码生成类
' 原作者:NetRube
'--------------------------------------
Class Fly38_VerifyCode
Public GlobalColorTable(), LocalColorTable()
Public TransparentColorIndex, UseTransparency
Public GIF89a
Public Comment

Private FGroundColorIndex, BGroundColorIndex
Private Image
Private GlobalColorTableSize, GlobalColorTableFlag, LocalColorTableSize, LocalColorTableFlag
Private Width_, Height_
Private LeftPosition, TopPosition
Private Bits, ColorResolution, CodeSize
Private PixelAspectRatio
Private SortFlag, InterlaceFlag
Private Seperator, GraphicControl, EndOfImage
Private Reserved

Private Font
Private Letter(19)

Private Sub Class_Initialize()
Image = ""

GIF89a = False

ReDim GlobalColorTable(256)
GlobalColorTableSize = 7
GlobalColorTableFlag = True

GlobalColorTable(2) = RGB(255, 0, 0)
GlobalColorTable(3) = RGB(0, 255, 0)
GlobalColorTable(4) = RGB(0, 0, 255)
GlobalColorTable(5) = RGB(255, 255, 0)
GlobalColorTable(6) = RGB(0, 255, 255)
GlobalColorTable(7) = RGB(255, 0, 255)

ReDim LocalColorTable(0)
LocalColorTableSize = 0
LocalColorTableFlag = False

ColorResolution = 7
Bits = 7
CodeSize = 7

BGroundColorIndex = 0
FGroundColorIndex = 1
TransparentColorIndex = 0
UseTransparency = False

LeftPosition = 0
TopPosition = 0
Width_ = 20
Height_ = 20

Clear

PixelAspectRatio = 0
SortFlag = False
InterlaceFlag = False
Seperator = Asc(",")
GraphicControl = Asc("!")
EndOfImage = Asc(";")

Comment = ""

Reserved = 0

Set Font = Server.CreateObject("Scripting.Dictionary")

Letter(0) = "00000000000000"
Letter(1) = "00001111100000"
Letter(2) = "00011111110000"
Letter(3) = "00111000111000"
Letter(4) = "00110000011100"
Letter(5) = "01110000001100"
Letter(6) = "01100000001110"
Letter(7) = "01100000001110"
Letter(8) = "11100000001110"
Letter(9) = "11000000001110"
Letter(10) = "11000000001110"
Letter(11) = "11100000001110"
Letter(12) = "11100000001100"
Letter(13) = "11100000001100"
Letter(14) = "01100000001100"
Letter(15) = "01110000011100"
Letter(15) = "00111000011000"
Letter(16) = "00011111110000"
Letter(17) = "00001111100000"
Letter(18) = "00000000000000"
Font.Add "0", Letter

Letter(0) = "00000000000000"
Letter(1) = "00000001110000"
Letter(2) = "00000001110000"
Letter(3) = "00000011100000"
Letter(4) = "00000011000000"
Letter(5) = "00000011000000"
Letter(6) = "00000011000000"
Letter(7) = "00000111000000"
Letter(8) = "00000111000000"
Letter(9) = "00000111000000"
Letter(10) = "00000110000000"
Letter(11) = "00000110000000"
Letter(12) = "00000110000000"
Letter(13) = "00000110000000"
Letter(14) = "00000110000000"
Letter(15) = "00000110000000"
Letter(15) = "00000110000000"
Letter(16) = "00000110000000"
Letter(17) = "00000010000000"
Letter(18) = "00000000000000"
Font.Add "1", Letter

Letter(0) = "00000000000000"
Letter(1) = "00001111110000"
Letter(2) = "00011111111000"
Letter(3) = "00111000011100"
Letter(4) = "01110000011100"
Letter(5) = "01110000011000"
Letter(6) = "01100000011000"
Letter(7) = "00000000111000"
Letter(8) = "00000001110000"
Letter(9) = "00000001110000"
Letter(10) = "00000011000000"
Letter(11) = "00000111000000"
Letter(12) = "00001110000000"
Letter(13) = "00011000000000"
Letter(14) = "00011000000000"
Letter(15) = "00110000011100"
Letter(16) = "01101111111100"
Letter(17) = "01111111111110"
Letter(18) = "01111100000000"
Letter(19) = "00000000000000"
Font.Add "2", Letter

Letter(0) = "00000000000000"
Letter(1) = "00001111111000"
Letter(2) = "00111111111000"
Letter(3) = "01110000111100"
Letter(4) = "01100000011000"
Letter(5) = "01000000111000"
Letter(6) = "00000000111000"
Letter(7) = "00000001110000"
Letter(8) = "00000011000000"
Letter(9) = "00000111110000"
Letter(10) = "00000100111000"
Letter(11) = "00000000011100"
Letter(12) = "00000000011100"
Letter(13) = "00000000011100"
Letter(14) = "00000000011100"
Letter(15) = "00000000011000"
Letter(16) = "11100000111000"
Letter(17) = "11111111110000"
Letter(18) = "01111111100000"
Letter(19) = "00000000000000"
Font.Add "3", Letter

Letter(0) = "00000000000000"
Letter(1) = &qu
[] [返回上一页] [打 印] [收 藏]  
 ∷相关技术评论  (评论内容只代表网友观点,与本站立场无关!) [查看发表评论...]
 
 中国教育资源网免费技术教程下载中心-站内广告 站内广告 中国教育资源网免费技术教程下载中心-站内广告 
 中国教育资源网站内搜索 站内搜索 中国教育资源网站内搜索 
 

   
 中国教育资源网免费技术教程下载中心-栏目导航 栏目导航 中国教育资源网免费技术教程下载中心-栏目导航 
· Dreamweaver · FrontPage
· CSSHTML · DOMJS
· Google排名 · 搜索研究
· 网络赚钱 · Alexa相关
· 建站交流 · 源码精华
· 经验技巧
 
中国教育资源网免费技术教程下载中心-相关教程  相关技术 中国教育资源网免费技术教程下载中心-相关教程
· 基于VERITASNetBack
· VERITASNetBackup的
 中国教育资源网免费技术教程下载中心-本月热门教程 本月热门 中国教育资源网免费技术教程下载中心-本月热门教程 
 
 中国教育资源网免费技术教程下载中心-本日热门论文 本日热门 中国教育资源网免费技术教程下载中心-本日热门论文 
 
关于本站 - 网站帮助 - 免费课件 - 美容 - 绿色软件 - 软件下载 - 广告合作 - 下载声明 - 友情连接 - 网站地图 - 网站留言
浙ICP备06010405号 Email:cnkjz@163.com 技术支持:名流设计
版权所有 Copyright© 2002-2004 名流