- <?
- $_SESSION['Number'] = mt_rand (0000000, 99999999);
- $img = imagecreatetruecolor(130, 30);
- $white = imagecolorallocate($img, 255, 255, 255);
- $red = imagecolorallocate($img, 255, 0, 0);
- $green = imagecolorallocate($img, 0, 255, 0);
- $blue = imagecolorallocate($img, 0, 0, 255);
- $random_color = imagecolorallocate($img, rand(180,240), rand(180,240), rand(180,240));
- imagestring($img, 5, rand(0,50), rand(0,15), $_SESSION['Number'], $random_color);
- header('Content-type: image/jpeg');
- imagejpeg($img);
- ?>