本文整理汇总了PHP中XenForo_Template_Helper_Core::styleProperty方法的典型用法代码示例。如果您正苦于以下问题:PHP XenForo_Template_Helper_Core::styleProperty方法的具体用法?PHP XenForo_Template_Helper_Core::styleProperty怎么用?PHP XenForo_Template_Helper_Core::styleProperty使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类XenForo_Template_Helper_Core
的用法示例。
在下文中一共展示了XenForo_Template_Helper_Core::styleProperty方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: template_create
public static function template_create(&$templateName, array &$params, XenForo_Template_Abstract $template)
{
if (defined('WIDGET_FRAMEWORK_LOADED')) {
WidgetFramework_Core::getInstance()->prepareWidgetsFor($templateName, $params, $template);
WidgetFramework_Core::getInstance()->prepareWidgetsForHooksIn($templateName, $params, $template);
if ($templateName === 'PAGE_CONTAINER') {
$template->preloadTemplate('wf_hook_moderator_bar');
$template->preloadTemplate('wf_revealer');
if (WidgetFramework_Option::get('indexNodeId')) {
// preload our links template for performance
$template->preloadTemplate('wf_home_navtab_links');
}
WidgetFramework_Template_Extended::WidgetFramework_setPageContainer($template);
if (isset($params['contentTemplate']) and $params['contentTemplate'] === 'wf_widget_page_index' and empty($params['selectedTabId'])) {
// make sure a navtab is selected if user is viewing our (as index) widget page
if (!XenForo_Template_Helper_Core::styleProperty('wf_homeNavTab')) {
// oh, our "Home" navtab has been disable...
// try something from $params['tabs'] OR $params['extraTabs']
if (isset($params['tabs']) and isset($params['extraTabs'])) {
WidgetFramework_Helper_Index::setNavtabSelected($params['tabs'], $params['extraTabs']);
}
}
}
}
}
}
示例2: _addMoodDisplay
/**
* Helper function to add mood display into hook.
*
* @param XenForo_Template_Abstract
* @param string Needle to hook on to (empty for pure pre/append)
* @param string Contents of the hook block
* @param array User of the mood to be displayed
* @param string Style property to check (null to disable check)
* @param boolean Set to true to prepend, false to append
* @param string Override mood display template
*
* @return void
*/
protected static function _addMoodDisplay(XenForo_Template_Abstract $template, $needle, &$contents, $user, $styleProperty = NULL, $prepend = TRUE, $templateName = NULL)
{
// check style property
if (isset($styleProperty) and XenForo_Template_Helper_Core::styleProperty($styleProperty) == FALSE) {
return;
}
// generate the mood template
$moodDisplay = self::_getMoodTemplate($template, $user, $templateName);
// pure prepend/append
if (empty($needle)) {
// do a bit of flip-flopping
if ($prepend) {
$contents = $moodDisplay . $contents;
} else {
$contents = $contents . $moodDisplay;
}
return;
}
// do more flip-flopping!
if ($prepend) {
$replace = $moodDisplay . $needle;
} else {
$replace = $needle . $moodDisplay;
}
// add it to the master template
$contents = str_replace($needle, $replace, $contents);
}
示例3: _getDefaultAvatarUrl
/**
* Returns the default gender-specific avatar URL
*
* @param string $size (s,m,l)
*
* @return string
*/
protected static function _getDefaultAvatarUrl(array $socialForum, $size)
{
if (XenForo_Application::get('options')->th_socialGroups_useCreatorAvatar && $socialForum['user_id']) {
$user = XenForo_Model::create('XenForo_Model_User')->getUserById($socialForum['user_id']);
if ($user) {
return XenForo_Template_Helper_Core::getAvatarUrl($user, $size);
}
}
if (!($imagePath = XenForo_Template_Helper_Core::styleProperty('imagePath'))) {
$imagePath = 'styles/default';
}
return "{$imagePath}/xenforo/avatars/avatar_{$size}.png";
}
示例4: actionIndex
public function actionIndex()
{
$code = $this->_input->filterSingle('code', XenForo_Input::STRING);
$mask = $this->_getMaskOrError($code, array('join' => ThemeHouse_ImageRestrict_Model_Mask::FETCH_POST));
$maskModel = $this->_getMaskModel();
if (!$maskModel->canViewStuffInPost($mask)) {
if (!($imagePath = XenForo_Template_Helper_Core::styleProperty('imagePath'))) {
$imagePath = 'styles/default';
}
$mask['url'] = $imagePath . '/xenforo/icons/moderated.png';
}
return $this->responseRedirect(XenForo_ControllerResponse_Redirect::SUCCESS, $mask['url']);
}
示例5: goToTop
public static function goToTop(&$templateName, array &$params, XenForo_Template_Abstract $template)
{
switch ($templateName) {
case 'PAGE_CONTAINER':
//Init
$visitor = XenForo_Visitor::getInstance();
$GttBrowser = '';
// Type: Normal/Mini/(None)
$GttType = XenForo_Template_Helper_Core::styleProperty('gototopType');
$typeMobile = XenForo_Template_Helper_Core::styleProperty('gototopTypeMobile');
$typeTablet = XenForo_Template_Helper_Core::styleProperty('gototopTypeTablet');
//External Addon
if (class_exists('Sedo_DetectBrowser_Listener_Visitor') && isset($visitor->getBrowser)) {
//Check if mobile and not tablet
if ($visitor->getBrowser['isMobile'] && !$visitor->getBrowser['isTablet']) {
if ($typeMobile == 'none') {
break;
}
$GttType = $typeMobile;
}
//Check if tablet
if ($visitor->getBrowser['isTablet']) {
if (in_array($typeTablet, array('none', 'error'))) {
break;
}
$GttType = $typeTablet;
}
//Check if IE6
if ($visitor->getBrowser['IEis'] == 6) {
$GttBrowser = 'IE';
}
} else {
//XenForo Mobile
if (XenForo_Visitor::isBrowsingWith('mobile')) {
if ($typeMobile == 'none') {
break;
}
$GttType = $typeMobile;
}
//IE6 self function
$checkIE6 = self::isBadIE('target', '1-6');
if ($checkIE6 === true) {
$GttBrowser = 'IE';
}
}
$extraParams['goToTop'] = array('type' => $GttType, 'browser' => $GttBrowser);
$params += $extraParams;
break;
}
}
示例6: MceIntegration
public static function MceIntegration($mceConfigObj)
{
if (is_array($mceConfigObj)) {
return false;
}
$xenOptions = XenForo_Application::get('options');
if ($mceConfigObj->buttonIsEnabled('tags_highlighter')) {
$hlParams = array('adv_hl_norm' => array('open' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_normal_tags_open'), 'options' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_normal_tags_options'), 'close' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_normal_tags_close')), 'adv_hl_spe' => array('open' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_special_tags_open'), 'options' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_special_tags_options'), 'close' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_special_tags_close'), 'content' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_special_tags_content')), 'adv_hl_tag_separator' => XenForo_Template_Helper_Core::styleProperty('adv_highlight_tag_options_separator'));
$mceConfigObj->addMcePlugin('xenadvhl');
$mceConfigObj->addBulkMceParams($hlParams);
}
if ($xenOptions->sedo_bbm_adv_tinyquattro_menu_integration) {
$menuItems = array('bbm_sedo_bimg', 'bbm_sedo_slides', '|', 'bbm_sedo_article', 'bbm_sedo_fieldset', 'bbm_sedo_encadre', 'bbm_sedo_spoilerbb', '|', 'bbm_sedo_latex', 'bbm_sedo_gview', 'bbm_sedo_picasa');
$mceConfigObj->addMenu('adv_insert', 'insert', 'Advanced Insert', $menuItems);
$mceConfigObj->addMenuItem('tags_highlighter', 'view', '@view_1', true);
}
//Zend_Debug::dump($mceConfigObj->getMenusGrid());
//Zend_Debug::dump($mceConfigObj->getAvailableButtons());
}
示例7: htmlspecialchars
<form action="' . htmlspecialchars($requestPaths['requestUri'], ENT_QUOTES, 'UTF-8') . '" method="post" onsubmit="AdvLatexDialog.submit(); return false;" class="section">
<h1 class="heading">' . 'Latex Insertion Panel' . '</h1>
<div id="formbox">
<div class="secondaryContent">
' . 'Title:' . ' <input id="ctrl_title" name="title" type="text" class="textCtrl" style="width:' . XenForo_Template_Helper_Core::styleProperty('adv_template_normaltitlefield_width') . '" value="' . 'Auto' . '" />
<span class="advtopextra">' . 'Width:' . ' <input id="ctrl_width" name="width" type="text" class="textCtrl" style="width:' . XenForo_Template_Helper_Core::styleProperty('adv_template_widthfield_width') . '" value="' . 'Auto' . '" /> <input id="ctrl_widthtype" name="widthtype" type="text" class="textCtrl" style="width:15px" readonly="true" value="%" /></span>
<span class="advtopextra">' . 'Block align:' . '
<select name="type" id="ctrl_blockalign" class="textCtrl">
<option value="bleft">' . 'Normal left' . '</option>
<option value="bcenter">' . 'Normal center' . '</option>
<option value="bright">' . 'Normal right' . '</option>
<option value="fleft">' . 'Float left' . '</option>
<option value="fright">' . 'Float right' . '</option>
</select>
</span>
<div id="cmd_height" class="advtopextra">' . 'Height:' . ' <input id="ctrl_height" name="height" type="text" class="textCtrl" style="width:' . XenForo_Template_Helper_Core::styleProperty('adv_template_widthfield_width') . '" value="' . 'Auto' . '" /> <span id="heightpx">px</span></div>
</div>
<div class="primaryContent">
' . 'Type your latex code here' . '
<textarea name="text" id="ctrl_text" style="display: block; width: 98%; height: 98px; resize: none" class="textCtrl caption mceFocus"></textarea>
</div>
<div id="trigger_help" class="subHeading">' . 'Basic Commands (click here)' . '</div>
<div id="help_content">
<div class="primaryContent">
<table class="latex_helper">
<tr id="op_desc">
<td class="cmd">' . 'Command' . '</td>
<td class="desc">' . 'Description' . '</td>
<td class="example">' . 'Example' . '</td>
<td class="img">' . 'Display' . '</td>
</tr>
示例8: htmlspecialchars
$__compilerVar8 .= '
<div class="plusone shareControl">
<div class="g-plusone" data-size="medium" data-count="true" data-href="' . htmlspecialchars($__compilerVar5, ENT_QUOTES, 'UTF-8') . '"></div>
</div>
';
}
$__compilerVar8 .= '
';
if ($xenOptions['facebookLike']) {
$__compilerVar8 .= '
<div class="facebookLike shareControl">
';
$__extraData['facebookSdk'] = '';
$__extraData['facebookSdk'] .= '1';
$__compilerVar8 .= '
<fb:like href="' . htmlspecialchars($__compilerVar5, ENT_QUOTES, 'UTF-8') . '" show_faces="true" width="400" action="' . htmlspecialchars($xenOptions['facebookLikeAction'], ENT_QUOTES, 'UTF-8') . '" font="trebuchet ms" colorscheme="' . XenForo_Template_Helper_Core::styleProperty('fbColorScheme') . '"></fb:like>
</div>
';
}
$__compilerVar8 .= '
';
$__compilerVar7 .= $this->callTemplateHook('share_page_options', $__compilerVar8, array());
unset($__compilerVar8);
$__compilerVar7 .= '
';
if (trim($__compilerVar7) !== '') {
$__compilerVar6 .= '
';
$this->addRequiredExternal('css', 'share_page');
$__compilerVar6 .= '
示例9: rgba
.photosSidebar li .info {
position: absolute;
left: 0;
margin-bottom: 5px;
padding: 5px 10px;
background-color: rgba(0, 0, 0, 0.5);
top: 0;
color: #FFF;
width: 100%;
}
.photosSidebar li .info a.username {
color: #FFF;
font-weight: bold;
}
.sonnb_XenGallery_WidgetRenderer_Photo h3{
' . XenForo_Template_Helper_Core::styleProperty('sidebarBlockHeading') . ';
}
.photosSidebar.scrollable {
margin: 0 20px;
overflow: hidden;
position: relative;
display: block;
}
.photosSidebar.scrollable ul{
width: 20000em;
position: absolute;
top: 0;
}';
示例10: array
if (XenForo_Template_Helper_Core::styleProperty('messageShowHomepage') and $post['homepage']) {
$__compilerVar44 .= '
<dl class="pairsJustified">
<dt>' . 'Web' . ':</dt>
<dd><a href="' . XenForo_Template_Helper_Core::string('censor', array('0' => htmlspecialchars($post['homepage'], ENT_QUOTES, 'UTF-8'), '1' => '-')) . '" rel="nofollow" target="_blank" itemprop="url">' . XenForo_Template_Helper_Core::string('censor', array('0' => htmlspecialchars($post['homepage'], ENT_QUOTES, 'UTF-8'))) . '</a></dd>
</dl>
';
}
$__compilerVar44 .= '
';
$__compilerVar43 .= $this->callTemplateHook('message_user_info_extra', $__compilerVar44, array('user' => $post, 'isQuickReply' => $isQuickReply));
unset($__compilerVar44);
$__compilerVar43 .= '
';
if (XenForo_Template_Helper_Core::styleProperty('messageShowCustomFields') and $post['customFields']) {
$__compilerVar43 .= '
';
$__compilerVar45 = '';
$__compilerVar45 .= '
';
foreach ($userFieldsInfo as $fieldId => $fieldInfo) {
$__compilerVar45 .= '
';
if ($fieldInfo['viewable_message'] and ($fieldInfo['display_group'] != 'contact' or $post['allow_view_identities'] == 'everyone' or $post['allow_view_identities'] == 'members' and $visitor['user_id'])) {
$__compilerVar45 .= '
';
$__compilerVar46 = '';
$__compilerVar46 .= XenForo_Template_Helper_Core::callHelper('userFieldValue', array('0' => $fieldInfo, '1' => $post, '2' => $post['customFields'][$fieldId]));
if (trim($__compilerVar46) !== '') {
示例11: htmlspecialchars
';
$this->addRequiredExternal('css', 'editor_dialog');
$__output .= '
';
$this->addRequiredExternal('css', 'editor_dialog_advenc');
$__output .= '
</head>
<body id="adv_enc">
<form action="' . htmlspecialchars($requestPaths['requestUri'], ENT_QUOTES, 'UTF-8') . '" method="post" onsubmit="AdvEncDialog.submit(); return false;" class="section">
<h1 class="heading">' . 'Text Box Insertion Panel' . '</h1>
<div id="formbox">
<div style="width:100%" class="secondaryContent">
' . 'Title:' . ' <input id="ctrl_title" name="title" type="text" class="textCtrl" style="width:' . XenForo_Template_Helper_Core::styleProperty('adv_template_normaltitlefield_width') . '" value="' . 'Auto' . '" />
' . 'Width:' . ' <input id="ctrl_width" name="width" type="text" class="textCtrl" style="width:' . XenForo_Template_Helper_Core::styleProperty('adv_template_widthfield_width') . '" value="' . 'Auto' . '" /> <input id="ctrl_widthtype" name="widthtype" type="text" class="textCtrl" style="width:15px" readonly="true" value="%" />
</div>
<div class="primaryContent">
<ul id="selectlist">
<li>
<ul id="skins">
<li class="active"><div id="skin1">' . 'Skin 1' . '</div></li>
<li><div id="skin2">' . 'Skin 2' . '</div></li>
</ul>
<input id="ctrl_skin" name="skin" type="hidden" value="skin1" />
</li>
<li>
<ul id="float">
<li><div id="fleft">' . 'Float left' . '</div></li>
<li class="active"><div id="fright">' . 'Float right' . '</div></li>
</ul>
示例12: htmlspecialchars
$__compilerVar15 .= '
';
if ($doodle['link']) {
$__compilerVar15 .= '
<a href="' . htmlspecialchars($doodle['link'], ENT_QUOTES, 'UTF-8') . '"><img src="' . htmlspecialchars($doodle['image'], ENT_QUOTES, 'UTF-8') . '" alt="' . htmlspecialchars($doodle['holiday'], ENT_QUOTES, 'UTF-8') . '" title="' . htmlspecialchars($doodle['holiday'], ENT_QUOTES, 'UTF-8') . '" /></a>
';
} else {
$__compilerVar15 .= '
<img src="' . htmlspecialchars($doodle['image'], ENT_QUOTES, 'UTF-8') . '" alt="' . htmlspecialchars($doodle['holiday'], ENT_QUOTES, 'UTF-8') . '" title="' . htmlspecialchars($doodle['holiday'], ENT_QUOTES, 'UTF-8') . '" />
';
}
$__compilerVar15 .= '
';
} else {
$__compilerVar15 .= '
<img src="' . XenForo_Template_Helper_Core::styleProperty('headerLogoPath') . '" alt="' . htmlspecialchars($xenOptions['boardTitle'], ENT_QUOTES, 'UTF-8') . '" />
';
}
$__compilerVar15 .= '
</a></div>
';
$__compilerVar12 .= $this->callTemplateHook('header_logo', $__compilerVar15, array());
unset($__compilerVar15);
$__compilerVar12 .= '
<span class="helper"></span>
</div>';
$__compilerVar11 .= $__compilerVar12;
unset($__compilerVar12);
$__compilerVar11 .= '
';
示例13: array
$__compilerVar8 .= '
';
if (XenForo_Template_Helper_Core::styleProperty('wf_threads_fullForum')) {
$__compilerVar8 .= '
<span class="user">' . 'trong diễn đàn' . ' <a href="' . XenForo_Template_Helper_Core::link('forums', $thread['forum'], array()) . '">' . htmlspecialchars($thread['forum']['title'], ENT_QUOTES, 'UTF-8') . '</a></span>';
if (XenForo_Template_Helper_Core::styleProperty('wf_threads_fullDate')) {
$__compilerVar8 .= '<span class="divider">,</span>';
}
$__compilerVar8 .= '
';
}
$__compilerVar8 .= '
';
if (XenForo_Template_Helper_Core::styleProperty('wf_threads_fullDate')) {
$__compilerVar8 .= '
<a href="' . $link . '">' . XenForo_Template_Helper_Core::callHelper('datetimehtml', array($thread['post_date'], array('time' => '$thread.post_date'))) . '</a>
';
}
$__compilerVar8 .= '
';
$__compilerVar7 .= $this->callTemplateHook('wf_widget_threads_thread_full_info_main', $__compilerVar8, array('thread' => $thread));
unset($__compilerVar8);
$__compilerVar7 .= '
';
if (trim($__compilerVar7) !== '') {
$__output .= '
<div class="main">
' . $__compilerVar7 . '
示例14:
<?php
if (!class_exists('XenForo_Application', false)) {
die;
}
$__output = '';
$__output .= '.modm_ajaxchat_username { font-weight: bold;}
.modm_ajaxchat_timestamp { color: ' . XenForo_Template_Helper_Core::styleProperty('mutedTextColor') . '; font-style: italic; padding: 0 7px 0 3px;}
.modm_ajaxchat_message {}';
示例15: rgb
<div class="slide_likebox">
<div style="color: rgb(255, 255, 255); padding: 8px 5px 0pt 50px;">
<div class="FB_Loader"></div>
<span>
<iframe src="//www.facebook.com/plugins/likebox.php?href=http%3A%2F%2Fwww.facebook.com%2Fthongtin.congnghe.moinhat&width=198&height=368&colorscheme=light&show_faces=true&border_color=white&stream=false&header=false&appId=450679131640420" scrolling="no" frameborder="0" style="border:none; overflow:hidden; width:198px; height:368px;" allowtransparency="true"></iframe>
</span>
</div>
</div>
';
$__compilerVar150 = '';
$__compilerVar150 .= '
';
if ($visitor['show_notification_popup']) {
$__compilerVar150 .= '
';
$this->addRequiredExternal('css', 'gfnnotify');
$__compilerVar150 .= '
';
$this->addRequiredExternal('js', 'js/gfnnotify/notification.js');
$__compilerVar150 .= '
<div id="GFNNotification" data-url="' . XenForo_Template_Helper_Core::link('gfnnotify/get-notifications', false, array()) . '" data-timer="' . XenForo_Template_Helper_Core::styleProperty('notificationOpenTimer') . '" data-interval="' . XenForo_Template_Helper_Core::styleProperty('notificationInterval') . '" data-mark-read="' . XenForo_Template_Helper_Core::link('gfnnotify/mark-read', false, array()) . '"></div>
';
}
$__output .= $__compilerVar150;
unset($__compilerVar150);
$__output .= '
</body>
</html>';