Просмотр файла quote_bash/code.php

Размер файла: 1.52Kb
<?

///////////////////////////////
//   by OTMOPO3OK            //
//Site: http://wapsib.ru     //
//icq: 3865085               //
//E-mail: [email protected]  //
///////////////////////////////

@ini_set('display_errors',false);
session_start();
$rand = rand(1000,9999);
$_SESSION['checkcod']=$rand;
$picture = imagecreate (52, 21);
$bgcolor = imagecolorallocate($picture, 165, 165, 165);
$ntcolor = imagecolorallocate($picture, 200, 200, 200);    
for ($i=0; $i<=100; $i+=5) imageline($picture, $i, 0, $i, 100, $ntcolor);
for ($i=0; $i<=100; $i+=5) imageline($picture, 0, $i, 100, $i, $ntcolor);
$fontcolor1 = imagecolorallocate($picture,rand(0,111), rand(0,111), rand(0,111));
$fontcolor2 = imagecolorallocate($picture,rand(0,111), rand(0,111), rand(0,111));
$fontcolor3 = imagecolorallocate($picture,rand(0,111), rand(0,111), rand(0,111));
$fontcolor4 = imagecolorallocate($picture,rand(0,111), rand(0,111), rand(0,111));
$fontcolor5 = imagecolorallocate($picture,rand(0,111), rand(0,111), rand(0,111));
imagestring($picture, 11, 07, 1, substr($rand,0,1), $fontcolor1);
imagestring($picture, 11, 17, 6, substr($rand,1,1), $fontcolor2);
imagestring($picture, 11, 27, 1, substr($rand,2,1), $fontcolor3);
imagestring($picture, 11, 37, 6, substr($rand,3,1), $fontcolor4);
imagestring($picture, 11, 47, 1, substr($rand,4,1), $fontcolor5);
header("Content-type: image/png");
header("Cache-Control: no-cache, must-revalidate"); 
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
imagepng($picture);
imagedestroy($picture);

?>