File size: 599B
<?
include "setup.php";
$rand1 = rand(0000,9999);
mysql_query ("UPDATE gb_protect SET code='$rand1' WHERE id='1'");
$c = mysql_query ("SELECT * FROM gb_protect WHERE id='1'");
$cc = mysql_fetch_array($c);
$rand = $cc['code'];
if (!$image = @imagecreatefromgif('gif.gif'))
{
$image = imagecreate(88, 88);
$backgroundcolor = imagecolorallocate($image, 0, 0, 0);
imagefill($image, 0, 0, $backgroundcolor);
}
$fontcolor = imagecolorallocate($image, 0, 0, 0);
$ses = $rand;
imagestring($image, 5, 10, 5, $rand, $fontcolor);
header("Content-type: image/gif");
imagegif($image);
?>