All articles| All Pictures| All Softwares| All Video| Go home page| Write articles| Upload pictures

Reading number is top 10 articles
Ajax实现无刷新三联动下拉框_[Asp.Net教程]
Sql,Server,常用日期格式_[SQL,Server教程]
维护为SQL,Server保驾护航_[SQL,Server教程]
ASP.NET用Repeater控件显示数据_[Asp.Net教程]
网站建设中优化网站的实用技巧_百度优化_seo学堂
初学PHP指导:php.ini 配置详细选项_[PHP教程]
在SQL,Server2005中删除数据库用户和修改SQLServer数据库的登录名_mssql学习_编程技术
PHP开发中关于文件操作的疑难问答_php资料_编程技术
PHP生成动态WAP页面_[PHP教程]
PHP实例:FCKeditor 的配置和使用方法_[PHP教程]
Reading number is top 10 pictures
胸部遭到偷窥的女人们
Sell the barbecue as says father du breul2
Parking technology is great, that give you the keys can't stolen
2012 national geographic daily picture9
NeedWallpaper4
A man's favorite things10
From China fortress sora aoi3
青春清纯美女大集合1
Plump breasts1
yy365网站上的美女2
Download software ranking
The king of fighters 97(Mobile phone games-apk)
Wild things 2
Boxer vs Yellow5
卡丁车单机版
金山office2007
天龙八部最新服务端
Tram sex maniac 2 (H) rar bag12
电脑知识及技巧大合集
The Bermuda triangle3
jdk1.6 for windows
归海一刀 published in(发表于) 2014/2/10 6:49:36 Edit(编辑)
php程序如何生成验证码图片_[PHP教程]

php程序如何生成验证码图片_[PHP教程]

php程序如何生成验证码图片_[PHP教程]

//生成验证码图片
Header("Content-type: image/PNG");
srand((double)microtime()*1000000);//播下一个生成随机数字的种子,以方便下面随机数生成的使用

session_start();//将随机数存入session中
_SESSION['authnum']="";
im = imagecreate(62,20); //制定图片背景大小

black = ImageColorAllocate(im, 0,0,0); //设定三种颜色
white = ImageColorAllocate(im, 255,255,255);
gray = ImageColorAllocate(im, 200,200,200);

imagefill(im,0,0,gray); //采用区域填充法,设定(0,0)

while((authnum=rand()%100000)<10000);
//将四位整数验证码绘入图片
_SESSION['authnum']=authnum;
imagestring(im, 5, 10, 3, authnum, black);
// 用 col 颜色将字符串 s 画到 image 所代表的图像的 x,y 座标处(图像的左上角为 0, 0)。
//如果 font 是 1,2,3,4 或 5,则使用内置字体

for(i=0;i<200;i++) //加入干扰象素
{
randcolor = ImageColorallocate(im,rand(0,255),rand(0,255),rand(0,255));
imagesetpixel(im, rand()%70 , rand()%30 , randcolor);
}


ImagePNG(im);
ImageDestroy(im);
?>





添加到del.icio.us 添加到新浪ViVi 添加到百度搜藏 添加到POCO网摘 添加到天天网摘365Key 添加到和讯网摘 添加到天极网摘 添加到黑米书签 添加到QQ书签 添加到雅虎收藏 添加到奇客发现 diigo it 添加到饭否 添加到飞豆订阅 添加到抓虾收藏 添加到鲜果订阅 digg it 貼到funP 添加到有道阅读 Live Favorites 添加到Newsvine 打印本页 用Email发送本页 在Facebook上分享


Disclaimer Privacy Policy About us Site Map

If you have any requirements, please contact webmaster。(如果有什么要求,请联系站长)
Copyright ©2011-
uuhomepage.com, Inc. All rights reserved.