Home >Backend Development >PHP Tutorial >简单的php验证码生成

简单的php验证码生成

WBOY
WBOYOriginal
2016-06-23 13:33:36708browse

	//生成图片	$width="100";	$height="50";		//生成一个背景,默认黑色	$img=imagecreatetruecolor($width, $height);		//生成颜色	$background=imagecolorallocate($img,200,200,200);	$white=imagecolorallocate($img,255,255,255);	$blue=imagecolorallocate($img,0,0,64);		//替换背颜色	imagefill($img,0,0,$background);		//加入线条	for ($i=1;$i  <br> 
Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn