當前位置: 首頁>>代碼示例>>PHP>>正文


PHP PhpCaptcha::DisplayShadow方法代碼示例

本文整理匯總了PHP中PhpCaptcha::DisplayShadow方法的典型用法代碼示例。如果您正苦於以下問題:PHP PhpCaptcha::DisplayShadow方法的具體用法?PHP PhpCaptcha::DisplayShadow怎麽用?PHP PhpCaptcha::DisplayShadow使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在PhpCaptcha的用法示例。


在下文中一共展示了PhpCaptcha::DisplayShadow方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: image

 function image()
 {
     $imagesPath = APP . 'vendors' . DS . 'phpcaptcha' . '/fonts/';
     $aFonts = array($imagesPath . 'VeraBd.ttf', $imagesPath . 'VeraIt.ttf', $imagesPath . 'Vera.ttf');
     $oVisualCaptcha = new PhpCaptcha($aFonts, 220, 60);
     $oVisualCaptcha->UseColour(true);
     $oVisualCaptcha->SetNumLines(false);
     $oVisualCaptcha->DisplayShadow(false);
     //$oVisualCaptcha->SetOwnerText('Source: '.FULL_BASE_URL);
     $oVisualCaptcha->SetNumChars(5);
     $oVisualCaptcha->Create();
 }
開發者ID:vsanth,項目名稱:propertykon,代碼行數:12,代碼來源:captcha.php

示例2: array

     $verification_id = 'common';
 }
 $verification_settings = Settings::instance()->getValues('Image_verification');
 $fonts = array(Registry::get('config.dir.lib') . 'other/captcha/verdana.ttf');
 $c = new PhpCaptcha($verification_id, $fonts, $verification_settings['width'], $verification_settings['height']);
 // Set string length
 $c->SetNumChars($verification_settings['string_length']);
 // Set number of distortion lines
 $c->SetNumLines($verification_settings['lines_number']);
 // Set minimal font size
 $c->SetMinFontSize($verification_settings['min_font_size']);
 // Set maximal font size
 $c->SetMaxFontSize($verification_settings['max_font_size']);
 $c->SetGridColour($verification_settings['grid_color']);
 if ($verification_settings['char_shadow'] == 'Y') {
     $c->DisplayShadow(true);
 }
 if ($verification_settings['colour'] == 'Y') {
     $c->UseColour(true);
 }
 if ($verification_settings['string_type'] == 'digits') {
     $c->SetCharSet(array(2, 3, 4, 5, 6, 8, 9));
 } elseif ($verification_settings['string_type'] == 'letters') {
     $c->SetCharSet(range('A', 'F'));
 } else {
     $c->SetCharSet(fn_array_merge(range('A', 'F'), array(2, 3, 4, 5, 6, 8, 9), false));
 }
 if (!empty($verification_settings['background_image'])) {
     $c->SetBackgroundImages(fn_get_files_dir_path() . $verification_settings['background_image']);
 }
 $c->Create();
開發者ID:heg-arc-ne,項目名稱:cscart,代碼行數:31,代碼來源:image.php

示例3: array

 * along with Loquacity; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 */
include_once 'core/config.php';
if (defined(C_CAPTCHA_ENABLE) && C_CAPTCHA_ENABLE == 'true') {
    include_once 'core/3rdparty/captcha/php-captcha.inc.php';
    $fonts = 'core/3rdparty/captcha/fonts/';
    $aFonts = array($fonts . 'VeraBd.ttf', $fonts . 'VeraIt.ttf', $fonts . 'Vera.ttf');
    $captcha = new PhpCaptcha($aFonts, 200, 60);
    //Set user options
    $captcha->SetWidth(C_CAPTCHA_WIDTH);
    $captcha->SetHeight(C_CAPTCHA_HEIGHT);
    $captcha->SetNumChars(C_CAPTCHA_CHARACTERS);
    $captcha->SetNumLines(C_CAPTCHA_LINES);
    if (C_CAPTCHA_ENABLE_SHADOWS === 'true') {
        $captcha->DisplayShadow(true);
    }
    if (C_CAPTCHA_OWNER_TEXT === 'true') {
        $captcha->SetOwnerText(BLOGURL);
    }
    $captcha->SetCharSet(C_CAPTCHA_CHARACTER_SET);
    if (C_CAPTCHA_CASE_INSENSITIVE === 'true') {
        $captcha->CaseInsensitive(true);
    }
    //$captcha->SetEdith(C_CAPTCHA_WIDTH);
    $captcha->SetMinFontSize(C_CAPTCHA_MIN_FONT);
    $captcha->SetMaxFontSize(C_CAPTCHA_MAX_FONT);
    if (C_CAPTCHA_USE_COLOR === 'true') {
        $captcha->UseColour(true);
    }
    $captcha->SetFileType(C_CAPTCHA_GRAPHIC_TYPE);
開發者ID:BackupTheBerlios,項目名稱:loquacity-svn,代碼行數:31,代碼來源:visualcaptcha.php

示例4: array

<?php

////////////////////////////////////////////////////////////////////////////
//
// (c) phpChess Limited, 2004-2006, in association with Goliath Systems.
// All rights reserved. Please observe respective copyrights.
// phpChess - Chess at its best
// you can find us at http://www.phpchess.com.
//
////////////////////////////////////////////////////////////////////////////
require 'php-captcha.inc.php';
// define fonts
$aFonts = array('fonts/VeraBd.ttf');
// create new image
$oPhpCaptcha = new PhpCaptcha($aFonts, 150, 30);
$oPhpCaptcha->SetBackgroundImages('val.jpg');
$oPhpCaptcha->SetWidth(150);
$oPhpCaptcha->SetHeight(30);
$oPhpCaptcha->SetNumChars(5);
$oPhpCaptcha->SetMinFontSize(10);
$oPhpCaptcha->SetMinFontSize(12);
$oPhpCaptcha->UseColour(True);
$oPhpCaptcha->DisplayShadow(False);
$oPhpCaptcha->SetNumLines(250);
$oPhpCaptcha->Create();
開發者ID:robertohernando,項目名稱:phpchess,代碼行數:25,代碼來源:img_validate.php


注:本文中的PhpCaptcha::DisplayShadow方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。