Пример #1
0
 /**
  * Generate captcha picture
  * 
  * @param TBGRequest $request The request object
  * @global array $_SESSION['activation_number'] The session captcha activation number
  */
 public function runCaptcha(TBGRequest $request)
 {
     TBGContext::loadLibrary('ui');
     if (!function_exists('imagecreatetruecolor')) {
         return $this->return404();
     }
     $this->getResponse()->setContentType('image/png');
     $this->getResponse()->setDecoration(TBGResponse::DECORATE_NONE);
     $chain = str_split($_SESSION['activation_number'], 1);
     $size = getimagesize(THEBUGGENIE_PATH . THEBUGGENIE_PUBLIC_FOLDER_NAME . DS . 'iconsets' . DS . TBGSettings::getIconsetName() . DS . 'numbers/0.png');
     $captcha = imagecreatetruecolor($size[0] * sizeof($chain), $size[1]);
     foreach ($chain as $n => $number) {
         $pic = imagecreatefrompng(THEBUGGENIE_PATH . THEBUGGENIE_PUBLIC_FOLDER_NAME . DS . 'iconsets' . DS . TBGSettings::getIconsetName() . DS . 'numbers/' . $number . '.png');
         imagecopymerge($captcha, $pic, $size[0] * $n, 0, 0, 0, imagesx($pic), imagesy($pic), 100);
         imagedestroy($pic);
     }
     imagepng($captcha);
     imagedestroy($captcha);
     return true;
 }
Пример #2
0
?>
password_mono.png'); }
	#openid-signin-button.persona-button span:after{ background-image: url('<?php 
echo TBGContext::getTBGPath() . 'iconsets/' . TBGSettings::getIconsetName() . '/';
?>
openid_providers.small/openid.ico.png'); }
	#regular-signin-button.persona-button span:after{ background-image: url('<?php 
echo TBGContext::getTBGPath() . 'iconsets/' . TBGSettings::getIconsetName() . '/';
?>
footer_logo.png'); }
	#forgot_password_username { background-image: url('<?php 
echo TBGContext::getTBGPath() . 'iconsets/' . TBGSettings::getIconsetName() . '/';
?>
user_mono.png'); }
	.login_popup .article h1 { background: url('<?php 
echo TBGContext::getTBGPath() . 'iconsets/' . TBGSettings::getIconsetName() . '/';
?>
logo_48.png') 0 0 no-repeat; }

	table.results_normal th.sort_asc { background-image: url('<?php 
echo TBGContext::getTBGPath();
?>
iconsets/oxygen/sort_down.png') !important; padding-left: 25px !important; }
	table.results_normal th.sort_desc { background-image: url('<?php 
echo TBGContext::getTBGPath();
?>
iconsets/oxygen/sort_up.png') !important; padding-left: 25px !important; }

	.markItUp .markItUpButton1 a { background-image:url('<?php 
echo TBGContext::getTBGPath();
?>
Пример #3
0
/**
 * Returns an <input type="image"> tag
 * 
 * @param string $image image source
 * @param array $params[optional] html parameters
 * @param bool $notheme[optional] whether this is a themed image or a top level path
 * 
 * @return string
 */
function image_submit_tag($image, $params = array(), $notheme = false)
{
    $params['src'] = !$notheme ? TBGContext::getTBGPath() . 'iconsets/' . TBGSettings::getIconsetName() . '/' . $image : $image;
    return '<input type="image" ' . parseHTMLoptions($params) . ' />';
}
Пример #4
0
?>
" id="iconset" style="width: 300px;"<?php 
if ($access_level != TBGSettings::ACCESS_FULL) {
    ?>
 disabled<?php 
}
?>
>
			<?php 
foreach ($icons as $anIcon) {
    ?>
				<option value="<?php 
    echo $anIcon;
    ?>
"<?php 
    if (TBGSettings::getIconsetName() == $anIcon) {
        ?>
 selected<?php 
    }
    if ($access_level != TBGSettings::ACCESS_FULL) {
        ?>
 disabled<?php 
    }
    ?>
><?php 
    echo $anIcon;
    ?>
</option>
			<?php 
}
?>