예제 #1
0
<?php

session_start();
$CaptchaIMG = new Securimage();
$CaptchaIMG->doImage();
$_SESSION['capcha'] = $CaptchaIMG->_returnCapchaCode();
class Securimage
{
    var $basepath;
    var $image_width;
    var $image_height;
    var $image_type = 2;
    /* SI_IMAGE_JPEG -1, SI_IMAGE_PNG - 2, SI_IMAGE_GIF - 3 */
    var $code_length = 5;
    var $charset = 'ABCDEFGHKLMNPRSTUVWYZabcdefghklmnprstuvwyz23456789';
    var $gd_font_size;
    var $ttf_file;
    var $perturbation;
    var $text_angle_minimum;
    var $text_angle_maximum;
    var $text_x_start;
    var $image_bg_color;
    var $text_color;
    var $multi_text_color;
    var $text_transparency_percentage;
    var $num_lines = 10;
    var $line_color;
    var $draw_lines_over_text = true;
    var $signature_color;
    var $tmpimg;
    var $iscale;