mktime: ".mktime(date("Y-m-d"))."
mu: ".mktime(date('Y-m-d'))*rand()."
md5: ".md5(mktime(date("Y-m-d"))*rand())."
code: ".$_SESSION["securityCode"]."
";
exit;
}
//*/
$referenceid = md5(mktime(date("Y-m-d"))*rand());
$font = "/home2/karkare/public_html/fonts/VERDANA.TTF";
$im = imagecreatefromjpeg("graphics/bg".rand(1, 3).".jpg");
$lead = strlen(md5("jimmybuffett"));
$textstr = $_SESSION["securityCode"];
//Create random size, angle, and dark color
$size = rand(14, 18);
$angle = 1;
while ($angle != 0) {$angle = rand(-5, 5);}
$color = ImageColorAllocate($im, 255,255,0);
$shadow = ImageColorAllocate($im, 0,0,0);
//Determine text size, and use dimensions to generate x & y coordinates
$textsize = imagettfbbox($size, $angle, $font, $textstr);
$twidth = abs($textsize[2]-$textsize[0]);
$theight = abs($textsize[5]-$textsize[3]);
$x = (imagesx($im)/2)-($twidth/2)+(rand(-30, 30));
$y = (imagesy($im))-($theight/2);
//Add text to image
ImageTTFText($im, $size, $angle, $x-1, $y-1, $shadow, $font, $textstr);
ImageTTFText($im, $size, $angle, $x, $y-1, $shadow, $font, $textstr);
ImageTTFText($im, $size, $angle, $x-1, $y, $shadow, $font, $textstr);
ImageTTFText($im, $size, $angle, $x+1, $y+1, $shadow, $font, $textstr);
ImageTTFText($im, $size, $angle, $x, $y, $color, $font, $textstr);
// resize as necessary
$w = 300;$h = 70;
$new = imagecreatetruecolor($w,$h);
imagecopyresized($new, $im, 0, 0, 0, 0, $w, $h, imagesx($im), imagesy($im));
//Output Image
header("Content-Type: image/jpeg");
imagejpeg($im);
imagedestroy($im);
//End Output
exit;
?>