![]() |
|
首页 │ Apache │ Linux│ Java│ MySQL│ 注册│帮助 | |||
需要GD库支持,比较简单没有加图形混淆,需要的可以自行解决。其实就和刷漆一样,多刷几层就花了。
[php]
<?php
/*
* TEXT GUI.
* Copyright (C) 2004-2005 yueyang
*
* Licensed under the terms of the GNU Lesser General Public License
* (http://www.opensource.org/licenses/lgpl-license.php)
*
* For further information go to http://www.8nm.net/
* or contact yueyang_cn@163.com.
*
*
* Authors:
* yueyang (yueyang_cn@163.com)
*/
$text_array = array();
for ($i=48;$i <= 122;$i++)
{
if ($i <= 57 || $i >= 97 || ($i >= 65 && $i <= 90))
$text_array[] = chr($i);
}
header ("Content-type: image/png");
$img = @imagecreate (60, 20)
or die ("Cannot Initialize new GD image stream");
$background_color = imagecolorallocate ($img, 255, 255, 255);
$text_color = imagecolorallocate ($img, 0, 0, 0);
$text = $text_array[array_rand($text_array)].$text_array[array_rand($text_array)].$text_array[array_rand($text_array)].$text_array[array_rand($text_array)].$text_array[array_rand($text_array)].$text_array[array_rand($text_array)];
imagestring ($img, 5, 0, 5, $text, $text_color);
imagepng ($img);
imagedestroy ($img);
?>
[/php]

