本文整理汇总了PHP中PBValidation::isNumber方法的典型用法代码示例。如果您正苦于以下问题:PHP PBValidation::isNumber方法的具体用法?PHP PBValidation::isNumber怎么用?PHP PBValidation::isNumber使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类PBValidation
的用法示例。
在下文中一共展示了PBValidation::isNumber方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: processShortcodeDivider
function processShortcodeDivider($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Align = new PBAlign();
$Border = new PBBorder();
$Validation = new PBValidation();
$style = array();
$class = array('pb-divider', 'pb-clear-fix');
if ($Validation->isNumber($attribute['line_width'], 0, 9999)) {
$style['width'] = $attribute['line_width'] . 'px';
}
if ($Validation->isNumber($attribute['line_height'], 0, 9999)) {
$style['border-bottom-width'] = $attribute['line_height'] . 'px';
}
if (array_key_exists($attribute['line_style'], $Border->style)) {
$style['border-style'] = $attribute['line_style'];
}
if ($Validation->isColor($attribute['line_color'])) {
$style['border-color'] = PBColor::getColor($attribute['line_color']);
}
if (array_key_exists($attribute['align'], $Align->align)) {
array_push($class, $Align->getCSSClass($attribute['align']));
}
if ($Validation->isNumber($attribute['margin_top'], 0, 9999)) {
$style['margin-top'] = $attribute['margin_top'] . 'px';
}
if ($Validation->isNumber($attribute['margin_bottom'], 0, 9999)) {
$style['margin-bottom'] = $attribute['margin_bottom'] . 'px';
}
array_push($class, $attribute['css_class']);
$html = '
<div' . PBHelper::createClassAttribute($class) . PBHelper::createStyleAttribute($style) . '></div>
';
return PBHelper::formatHTML($html);
}
示例2: processShortcodeVerticalGrid
function processShortcodeVerticalGrid($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$Validation = new PBValidation();
$this->lineNumber = 0;
$this->lineStyle = array('even' => array('name' => null, 'value' => null), 'odd' => array('name' => null, 'value' => null));
if ($Validation->isEmpty($content)) {
return $html;
}
$style = array();
if ($Validation->isNumber($attribute['column_name_width'], 1, 100)) {
$style['odd']['name']['width'] = $attribute['column_name_width'] . '%';
$style['even']['name']['width'] = $attribute['column_name_width'] . '%';
}
if ($Validation->isNumber($attribute['column_value_width'], 1, 100)) {
$style['odd']['value']['width'] = $attribute['column_value_width'] . '%';
$style['even']['value']['width'] = $attribute['column_value_width'] . '%';
}
if ($Validation->isColor($attribute['line_even_column_name_text_color'])) {
$style['even']['name']['color'] = PBColor::getColor($attribute['line_even_column_name_text_color']);
}
if ($Validation->isColor($attribute['line_even_column_value_text_color'])) {
$style['even']['value']['color'] = PBColor::getColor($attribute['line_even_column_value_text_color']);
}
if ($Validation->isColor($attribute['line_even_column_name_bg_color'])) {
$style['even']['name']['background-color'] = PBColor::getColor($attribute['line_even_column_name_bg_color']);
}
if ($Validation->isColor($attribute['line_even_column_value_bg_color'])) {
$style['even']['value']['background-color'] = PBColor::getColor($attribute['line_even_column_value_bg_color']);
}
if ($Validation->isColor($attribute['line_odd_column_name_text_color'])) {
$style['odd']['name']['color'] = PBColor::getColor($attribute['line_odd_column_name_text_color']);
}
if ($Validation->isColor($attribute['line_odd_column_value_text_color'])) {
$style['odd']['value']['color'] = PBColor::getColor($attribute['line_odd_column_value_text_color']);
}
if ($Validation->isColor($attribute['line_odd_column_name_bg_color'])) {
$style['odd']['name']['background-color'] = PBColor::getColor($attribute['line_odd_column_name_bg_color']);
}
if ($Validation->isColor($attribute['line_odd_column_value_bg_color'])) {
$style['odd']['value']['background-color'] = PBColor::getColor($attribute['line_odd_column_value_bg_color']);
}
$this->lineStyle['even']['name'] = PBHelper::createStyleAttribute($style['even']['name']);
$this->lineStyle['even']['value'] = PBHelper::createStyleAttribute($style['even']['value']);
$this->lineStyle['odd']['name'] = PBHelper::createStyleAttribute($style['odd']['name']);
$this->lineStyle['odd']['value'] = PBHelper::createStyleAttribute($style['odd']['value']);
$class = array('pb-vertical-grid', 'pb-clear-fix', $attribute['css_class']);
$html = '
<div' . PBHelper::createClassAttribute($class) . '>
<ul' . PBHelper::createClassAttribute(array('pb-reset-list')) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</ul>
</div>
';
return PBHelper::formatHTML($html, PBHelper::formatContent($content, true, false, false));
}
示例3: processShortcodeScreenPreloader
function processShortcodeScreenPreloader($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$Validation = new PBValidation();
if (!$Validation->isColor($attribute['bg_color'])) {
return $html;
}
if (!$Validation->isNumber($attribute['z_index'], 0, 999999)) {
return $html;
}
$style = array();
$class = array('pb-screen-preloader', $attribute['css_class']);
$style['z-index'] = $attribute['z_index'];
$style['background-color'] = PBColor::getColor($attribute['bg_color']);
$id = PBHelper::createId('pb_screen_preloader');
$html = '
<div' . PBHelper::createStyleAttribute($style) . PBHelper::createClassAttribute($class) . ' id="' . esc_attr($id) . '"></div>
<div class="pb-script-tag">
<script type="text/javascript">
jQuery(document).ready(function($)
{
$(\'#' . $id . '\').PBScreenPreloader();
});
</script>
</div>
';
return PBHelper::formatHTML($html);
}
示例4: processShortcodeHeaderSubheaderSubheader
function processShortcodeHeaderSubheaderSubheader($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$style = array();
$Font = new PBFont();
$Header = new PBHeader();
$Validation = new PBValidation();
if ($Validation->isEmpty($content)) {
return $html;
}
if (!array_key_exists($attribute['important'], $Header->important)) {
return $html;
}
if ($Validation->isNumber($attribute['font_size'], 1, 200, true)) {
$style['font-size'] = $attribute['font_size'] . 'px';
}
if (array_key_exists($attribute['font_weight'], $Font->weight)) {
$style['font-weight'] = $attribute['font_weight'];
}
if (array_key_exists($attribute['font_style'], $Font->style)) {
$style['font-style'] = $attribute['font_style'];
}
if ($Validation->isColor($attribute['font_color'])) {
$style['color'] = PBColor::getColor($attribute['font_color']);
}
if ($Validation->isNotEmpty($attribute['line_height'])) {
$style['line-height'] = $attribute['line_height'];
}
$class = array(array('pb-subheader'), array('pb-subheader-content'));
$html = '<h' . (int) $attribute['important'] . PBHelper::createClassAttribute($class[0]) . PBHelper::createStyleAttribute($style) . '><span' . PBHelper::createClassAttribute($class[1]) . '>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</span></h' . (int) $attribute['important'] . '>';
return PBHelper::formatHTML($html, $content);
}
示例5: processShortcodeCounterListItem
function processShortcodeCounterListItem($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$Validation = new PBValidation();
if ($Validation->isEmpty($attribute['name'])) {
return $html;
}
if (!$Validation->isNumber($attribute['value'], 0, 99999, false)) {
return $html;
}
$lineCharacterAfter = null;
$lineCharacterBefore = null;
if ($Validation->isNotEmpty($this->character['before'])) {
$lineCharacterBefore = '<span' . PBHelper::createClassAttribute(array('pb-counter-list-value-character-before')) . '>' . esc_html($this->character['before']) . '</span>';
}
if ($Validation->isNotEmpty($this->character['after'])) {
$lineCharacterAfter = '<span' . PBHelper::createClassAttribute(array('pb-counter-list-value-character-after')) . '>' . esc_html($this->character['after']) . '</span>';
}
$html = '
<li class="pb-value-' . (int) $attribute['value'] . '">
<span class="pb-counter-list-label">' . esc_html($attribute['name']) . '</span>
<span class="pb-counter-list-value">
' . $lineCharacterBefore . '
<span class="pb-counter-list-value-value">' . (int) $attribute['value'] . '</span>
' . $lineCharacterAfter . '
</span>
<span class="pb-counter-list-foreground"></span>
<span class="pb-counter-list-background"></span>
</li>
';
return PBHelper::formatHTML($html);
}
示例6: processShortcodeIframe
function processShortcodeIframe($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Validation = new PBValidation();
if ($Validation->isEmpty($attribute['src'])) {
return null;
}
$style = array(array(), array());
if ($Validation->isNumber($attribute['width'], 1, 9999)) {
$style[0]['width'] = (int) $attribute['width'] . 'px';
}
if ($Validation->isNumber($attribute['height'], 1, 9999)) {
$style[1]['height'] = (int) $attribute['height'] . 'px';
$style[1]['padding-bottom'] = '0px';
}
$class = array(array('pb-iframe', $attribute['css_class']), array('pb-iframe-content'));
$html = '<div' . PBHelper::createClassAttribute($class[0]) . PBHelper::createStyleAttribute($style[0]) . '><div' . PBHelper::createClassAttribute($class[1]) . PBHelper::createStyleAttribute($style[1]) . '><iframe src="' . esc_attr($attribute['src']) . '"></iframe></div></div>';
return PBHelper::formatCode($html);
}
示例7: processShortcodeSpace
function processShortcodeSpace($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$style = array();
$Validation = new PBValidation();
if ($Validation->isNumber($attribute['height'], -9999, 9999)) {
if ((int) $attribute['height'] >= 0) {
$style['height'] = (int) $attribute['height'] . 'px';
} else {
$style['margin-top'] = (int) $attribute['height'] . 'px';
}
}
$class = array('pb-space', 'pb-clear-fix', $attribute['css_class']);
$html = '<div' . PBHelper::createClassAttribute(array('pb-space-line')) . '></div><div' . PBHelper::createClassAttribute($class) . PBHelper::createStyleAttribute($style) . '></div>';
return PBHelper::formatHTML($html);
}
示例8: processShortcodeAudio
function processShortcodeAudio($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$option = array();
$this->track = array();
$this->trackIndex = 0;
$Validation = new PBValidation();
if ($Validation->isEmpty($content)) {
return $html;
}
if (!$Validation->isNumber($attribute['volume'], 0, 100)) {
return $html;
}
if (!$Validation->isBool($attribute['muted'])) {
return $html;
}
if (!$Validation->isBool($attribute['playlist_enable'])) {
return $html;
}
$attribute['volume'] /= 100;
$key = array('muted', 'volume', 'playlist_enable');
foreach ($key as $value) {
$option[$value] = $attribute[$value];
}
$id = PBHelper::createId('audio');
$idPlayer = PBHelper::createId('audio_player');
$idPlayerContainer = PBHelper::createId('audio_player_container');
do_shortcode($content);
if (!count($this->track)) {
return $html;
}
$html .= $this->createJPlayerTemplate($id, $idPlayer, $idPlayerContainer);
$html .= '
<div class="pb-script-tag">
<script type="text/javascript">
jQuery(document).ready(function($)
{
$(\'#' . $id . '\').PBAudio(' . json_encode(array('idPlayer' => $idPlayer, 'idPlayerContainer' => $idPlayerContainer)) . ',' . json_encode($option) . ',' . json_encode($this->track) . ');
});
</script>
</div>
';
return PBHelper::formatHTML($html);
}
示例9: processShortcodeList
function processShortcodeList($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Validation = new PBValidation();
if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'gr') {
$classBullet = null;
if ($Validation->isNotEmpty($attribute['bullet'])) {
$classBullet = 'pb-list-icon-name-' . PBHelper::createHash($attribute['bullet']);
}
$class = array('pb-list', 'pb-list-icon-type-gr', $classBullet, $attribute['css_class']);
} else {
$class = array('pb-list', 'pb-list-icon-type-fa', $attribute['css_class']);
}
$id = PBHelper::createId('pb_list');
$html = '<div' . PBHelper::createClassAttribute($class) . ' id="' . esc_attr($id) . '">' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '</div>';
if (PBComponentData::get($this->getComponentId(), 'icon_type') === 'fa' && $Validation->isNotEmpty($attribute['font_icon_name'])) {
$option = array();
$option['icon_type'] = 'fa';
if ($Validation->isNotEmpty($attribute['font_icon_name'])) {
$option['font_icon_name'] = $attribute['font_icon_name'];
}
if ($Validation->isColor($attribute['font_icon_color'])) {
$option['font_icon_color'] = $attribute['font_icon_color'];
}
if ($Validation->isNumber($attribute['font_icon_size'], 1, 200)) {
$option['font_icon_size'] = $attribute['font_icon_size'];
}
$html .= '
<div class="pb-script-tag">
<script type="text/javascript">
jQuery(document).ready(function($)
{
$(\'#' . $id . '\').PBList(' . json_encode($option) . ');
});
</script>
</div>
';
}
return PBHelper::formatHTML($html, $content);
}
示例10: processShortcodeVideo
function processShortcodeVideo($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$Validation = new PBValidation();
$src = $this->parseVideoURL($attribute['src'], $attribute['type']);
if ($src === false) {
return $html;
}
$style = array();
if ($Validation->isNumber($attribute['player_width'], 1, 9999)) {
$style['width'] = (int) $attribute['player_width'] . 'px';
}
$class = array(array('pb-video', $attribute['css_class']), array('pb-video-content'));
$html = '
<div' . PBHelper::createClassAttribute($class[0]) . PBHelper::createStyleAttribute($style) . '>
<div' . PBHelper::createClassAttribute($class[1]) . '>
<iframe src="' . esc_attr($src) . '" frameborder="0" allowfullscreen></iframe>
</div>
</div>
';
return PBHelper::formatHTML($html);
}
示例11: processShortcodeRedirect
function processShortcodeRedirect($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Validation = new PBValidation();
if ($Validation->isEmpty($attribute['url']) && $Validation->isEmpty($attribute['post_id'])) {
return;
}
if ($Validation->isEmpty($attribute['url'])) {
if ($Validation->isNumber($attribute['post_id'], 1, 99999999)) {
$url = get_permalink($attribute['post_id']);
} else {
return;
}
} else {
$url = $attribute['url'];
}
if (ob_get_contents()) {
ob_clean();
}
wp_redirect($url, $attribute['status']);
ob_end_flush();
exit;
}
示例12: processShortcodeBackgroundVideo
function processShortcodeBackgroundVideo($attribute, $content, $tag)
{
$html = null;
$option = array();
$Validation = new PBValidation();
$attribute = $this->processAttribute($tag, $attribute);
if (!$Validation->isBool($attribute['loop'])) {
return $html;
}
if (!$Validation->isBool($attribute['muted'])) {
return $html;
}
if (!$Validation->isNumber($attribute['volume'], 0, 100)) {
return $html;
}
if (!$Validation->isFloat($attribute['playback_rate'], -999.99, 999.99)) {
return $html;
}
if ($Validation->isEmpty($attribute['video_format_webm']) && $Validation->isEmpty($attribute['video_format_ogg']) && $Validation->isEmpty($attribute['video_format_mp4'])) {
return $html;
}
$key = array('loop', 'muted', 'poster', 'volume', 'position', 'playback_rate', 'video_format_mp4', 'video_format_ogg', 'video_format_webm');
foreach ($key as $value) {
$option[$value] = $attribute[$value];
}
$html = '
<div class="pb-script-tag">
<script type="text/javascript">
jQuery(document).ready(function($)
{
$(\'body\').PBBackgroundVideo(' . json_encode($option) . ');
});
</script>
</div>
';
return $html;
}
示例13: processShortcodeDropcap
function processShortcodeDropcap($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Validation = new PBValidation();
$style = array();
$class = array('pb-dropcap', 'pb-clear-fix', $attribute['css_class']);
if ($Validation->isNumber($attribute['font_size'], 1, 100)) {
$style['font-size'] = $attribute['font_size'] . 'px';
}
if ($Validation->isColor($attribute['font_color'])) {
$style['color'] = PBColor::getColor($attribute['font_color']);
}
if ($Validation->isColor($attribute['bg_color'])) {
$style['background-color'] = PBColor::getColor($attribute['bg_color']);
}
$letter = mb_substr($content, 0, 1);
$content = mb_substr($content, 1);
$html = '
<p' . PBHelper::createClassAttribute($class) . '>
<span class="pb-dropcap-first-letter" ' . PBHelper::createStyleAttribute($style) . '>' . $letter . '</span>' . PLUGIN_PAGE_BUILDER_SHORTCODE_CONTENT . '
</p>
';
return PBHelper::formatHTML($html, PBHelper::formatContent($content, true, false, false));
}
示例14: processShortcodeZAccordion
function processShortcodeZAccordion($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$Image = new PBImage();
$Easing = new PBEasing();
$Validation = new PBValidation();
$html = null;
$imageHTML = null;
$imageBoxHTML = null;
$option = array();
if (!array_key_exists($attribute['data_source'], $this->dataSource)) {
return $html;
}
if ($attribute['data_source'] == 1) {
$query = PBFile::getImage(explode(',', $attribute['image']));
if ($query === false) {
return $html;
}
if (!count($query->posts)) {
return $html;
}
} else {
$argument = array('meta_query' => array(array('key' => '_thumbnail_id')));
if ($Validation->isNotEmpty($attribute['post_type'])) {
$argument['post_type'] = explode(',', $attribute['post_type']);
}
if ($Validation->isNotEmpty($attribute['post_status'])) {
$argument['post_status'] = explode(',', $attribute['post_status']);
}
if ($Validation->isNotEmpty($attribute['post__in'])) {
$argument['post__in'] = explode(',', $attribute['post__in']);
}
if ($Validation->isNotEmpty($attribute['post__not_in'])) {
$argument['post__not_in'] = explode(',', $attribute['post__not_in']);
}
if ($Validation->isNotEmpty($attribute['posts_per_page'])) {
$argument['posts_per_page'] = $attribute['posts_per_page'] == -2 ? -1 : $attribute['posts_per_page'];
}
if ($Validation->isNotEmpty($attribute['orderby'])) {
$argument['orderby'] = $attribute['orderby'];
}
if ($Validation->isNotEmpty($attribute['order'])) {
$argument['order'] = $attribute['order'];
}
$query = new WP_Query($argument);
if ($query === false) {
return $html;
}
if ($query->post_count == 0) {
return $html;
}
}
if (!PBFile::isWPImage($attribute['image_size'])) {
return $html;
}
if (!$Validation->isBool($attribute['preloader_enable'])) {
return $html;
}
if (!$Validation->isNumber($attribute['starting_slide'], 0, 999)) {
return $html;
}
if (!$Validation->isNumber($attribute['timeout'], 0, 99999)) {
return $html;
}
if (!$Validation->isNumber($attribute['speed'], 0, 99999)) {
return $html;
}
if (!$Validation->isBool($attribute['auto'])) {
return $html;
}
if (!$Validation->isBool($attribute['pause'])) {
return $html;
}
if (!array_key_exists($attribute['easing'], $Easing->easingType)) {
return $html;
}
if (!array_key_exists($attribute['trigger'], $this->tabOpenTriggerEvent)) {
return $html;
}
if (!$Validation->isBool($attribute['display_slide_title'])) {
return $html;
}
if (!$Validation->isBool($attribute['display_slide_excerpt'])) {
return $html;
}
$imageSize = $Image->getImageDimension($attribute['image_size']);
if ($imageSize === false) {
return $html;
}
$key = array('preloader_enable', 'starting_slide', 'timeout', 'speed', 'auto', 'pause', 'easing', 'trigger', 'display_slide_title', 'display_slide_excerpt');
foreach ($key as $index) {
$option[$index] = $attribute[$index];
}
$option['width'] = $imageSize['width'];
$option['height'] = $imageSize['height'];
$class = array(array(), array(), array(), array());
array_push($class[0], 'pb-zaccordion', $attribute['css_class']);
array_push($class[1], 'pb-reset-list');
if ($attribute['preloader_enable'] == 1) {
array_push($class[1], 'pb-preloader');
//.........这里部分代码省略.........
示例15: processShortcodeBox
function processShortcodeBox($attribute, $content, $tag)
{
$attribute = $this->processAttribute($tag, $attribute);
$html = null;
$option = array();
$style = array(array(), array());
$Border = new PBBorder();
$Validation = new PBValidation();
/***/
if (!$Validation->isBool($attribute['icon_enable'])) {
return $html;
}
if (!array_key_exists($attribute['icon_size'], $this->icon)) {
return $html;
}
if (!array_key_exists($attribute['icon_position'], $this->iconPosition)) {
return $html;
}
/***/
if ($Validation->isColor($attribute['background_color'])) {
$style[0]['background-color'] = PBColor::getColor($attribute['background_color']);
}
if (array_key_exists($attribute['border_top_style'], $Border->style)) {
$style[0]['border-top-style'] = $attribute['border_top_style'];
}
if ($Validation->isNumber($attribute['border_top_width'], 0, 999)) {
$style[0]['border-top-width'] = $attribute['border_top_width'] . 'px';
}
if ($Validation->isColor($attribute['border_top_color'])) {
$style[0]['border-top-color'] = PBColor::getColor($attribute['border_top_color']);
}
if ($Validation->isNumber($attribute['border_top_radius'], 0, 999)) {
$style[0]['-webkit-border-top-left-radius'] = $attribute['border_top_radius'] . 'px';
$style[0]['-moz-border-radius-topleft'] = $attribute['border_top_radius'] . 'px';
$style[0]['border-top-left-radius'] = $attribute['border_top_radius'] . 'px';
}
if (array_key_exists($attribute['border_right_style'], $Border->style)) {
$style[0]['border-right-style'] = $attribute['border_right_style'];
}
if ($Validation->isNumber($attribute['border_right_width'], 0, 999)) {
$style[0]['border-right-width'] = $attribute['border_right_width'] . 'px';
}
if ($Validation->isColor($attribute['border_right_color'])) {
$style[0]['border-right-color'] = PBColor::getColor($attribute['border_right_color']);
}
if ($Validation->isNumber($attribute['border_right_radius'], 0, 999)) {
$style[0]['-webkit-border-top-right-radius'] = $attribute['border_right_radius'] . 'px';
$style[0]['-moz-border-radius-topright'] = $attribute['border_right_radius'] . 'px';
$style[0]['border-top-right-radius'] = $attribute['border_right_radius'] . 'px';
}
if (array_key_exists($attribute['border_bottom_style'], $Border->style)) {
$style[0]['border-bottom-style'] = $attribute['border_bottom_style'];
}
if ($Validation->isNumber($attribute['border_bottom_width'], 0, 999)) {
$style[0]['border-bottom-width'] = $attribute['border_bottom_width'] . 'px';
}
if ($Validation->isColor($attribute['border_bottom_color'])) {
$style[0]['border-bottom-color'] = PBColor::getColor($attribute['border_bottom_color']);
}
if ($Validation->isNumber($attribute['border_bottom_radius'], 0, 999)) {
$style[0]['-webkit-border-bottom-right-radius'] = $attribute['border_bottom_radius'] . 'px';
$style[0]['-moz-border-radius-bottomright'] = $attribute['border_bottom_radius'] . 'px';
$style[0]['border-bottom-right-radius'] = $attribute['border_bottom_radius'] . 'px';
}
if (array_key_exists($attribute['border_left_style'], $Border->style)) {
$style[0]['border-left-style'] = $attribute['border_left_style'];
}
if ($Validation->isNumber($attribute['border_left_width'], 0, 999)) {
$style[0]['border-left-width'] = $attribute['border_left_width'] . 'px';
}
if ($Validation->isColor($attribute['border_left_color'])) {
$style[0]['border-left-color'] = PBColor::getColor($attribute['border_left_color']);
}
if ($Validation->isNumber($attribute['border_left_radius'], 0, 999)) {
$style[0]['-webkit-border-bottom-left-radius'] = $attribute['border_left_radius'] . 'px';
$style[0]['-moz-border-radius-bottomleft'] = $attribute['border_left_radius'] . 'px';
$style[0]['border-bottom-left-radius'] = $attribute['border_left_radius'] . 'px';
}
if ($Validation->isNumber($attribute['padding_top'], 0, 999)) {
$style[0]['padding-top'] = $attribute['padding_top'] . 'px';
}
if ($Validation->isNumber($attribute['padding_right'], 0, 999)) {
$style[0]['padding-right'] = $attribute['padding_right'] . 'px';
}
if ($Validation->isNumber($attribute['padding_bottom'], 0, 999)) {
$style[0]['padding-bottom'] = $attribute['padding_bottom'] . 'px';
}
if ($Validation->isNumber($attribute['padding_left'], 0, 999)) {
$style[0]['padding-left'] = $attribute['padding_left'] . 'px';
}
if ($Validation->isColor($attribute['text_color_link'])) {
$option['out']['color'] = PBColor::getColor($attribute['text_color_link']);
}
if ($Validation->isColor($attribute['text_color_link_hover'])) {
$option['in']['color'] = PBColor::getColor($attribute['text_color_link_hover']);
}
$id = PBHelper::createId('pb_box');
$class[0] = array('pb-box', 'pb-clear-fix', $attribute['css_class']);
if ($attribute['icon_enable'] == 1) {
array_push($class[0], 'pb-box-icon');
//.........这里部分代码省略.........