本文整理汇总了PHP中fixShortcode函数的典型用法代码示例。如果您正苦于以下问题:PHP fixShortcode函数的具体用法?PHP fixShortcode怎么用?PHP fixShortcode使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了fixShortcode函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的PHP代码示例。
示例1: ux_tabgroup_vertical
function ux_tabgroup_vertical($params, $content = null)
{
$GLOBALS['tabs'] = array();
$GLOBALS['tab_count'] = 0;
$i = 1;
$randomid = rand();
extract(shortcode_atts(array('title' => '', 'style' => 'normal'), $params));
$content = fixShortcode($content);
if (is_array($GLOBALS['tabs'])) {
foreach ($GLOBALS['tabs'] as $key => $tab) {
$current = $key == 0 ? ' current-menu-item' : '';
// Set first menu item active by default.
$active = $key == 0 ? ' active' : '';
// Set first tab active by default.
$tabs[] = '<li class="tab' . $current . '"><a href="#panel' . $randomid . $i . '">' . $tab['title'] . '</a></li>';
$panes[] = '<div class="tabs-inner' . $active . '" id="panel' . $randomid . $i . '">' . fixShortcode($tab['content']) . '</div>';
$i++;
}
if ($title) {
$title = '<h3>' . $title . '</h3>';
}
$return = '
<div class="row collapse vertical-tabs shortcode_tabgroup_vertical pos_' . $style . '">
' . $title . '
<div class="large-3 columns"><ul class="tabs-nav">' . implode("\n", $tabs) . '</ul></div><div class="large-9 columns">' . implode("\n", $panes) . '</div></div>';
}
return $return;
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:28,代码来源:tabs.php
示例2: uxLightboxShortcode
function uxLightboxShortcode($atts, $content = null)
{
$sliderrandomid = rand();
ob_start();
extract(shortcode_atts(array('id' => 'enter-id-here', 'width' => '600px', 'padding' => '20px', 'button' => '', 'button_text' => ''), $atts));
?>
<div id="<?php
echo $id;
?>
" class="mfp-hide my-mfp-zoom-in lightbox-white" style="max-width:<?php
echo $width;
?>
;padding:<?php
echo $padding;
?>
">
<?php
echo fixShortcode($content);
?>
</div><!-- Lightbox-<?php
echo $id;
?>
-->
<script>
jQuery(document).ready(function($) {
$('a[href="#<?php
echo $id;
?>
"]').addClass('open-popup-link-<?php
echo $id;
?>
');
$('.open-popup-link-<?php
echo $id;
?>
').magnificPopup({
type:'inline',
midClick: true,
mainClass: 'my-mfp-zoom-in product-zoom-lightbox',
removalDelay: 300
});
$('.open-popup-link-<?php
echo $id;
?>
').click(function(e){
e.preventDefault();
});
});
</script>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:59,代码来源:lightbox.php
示例3: ux_price_table
function ux_price_table($atts, $content = null)
{
extract(shortcode_atts(array('title' => 'Title', 'price' => '$99.99', 'description' => 'Description', 'button_style' => 'small alt-button', 'button_text' => 'Buy Now', 'button_link' => '', 'featured' => 'false'), $atts));
ob_start();
?>
<div class="ux_price_table text-center <?php
if ($featured == 'true') {
?>
featured-table box-shadow<?php
}
?>
">
<ul class="pricing-table">
<li class="title"><?php
echo $title;
?>
</li>
<li class="price"><?php
echo $price;
?>
</li>
<li class="description"><?php
echo $description;
?>
</li>
<?php
echo fixShortcode($content);
?>
<?php
if ($button_style) {
?>
<li class="cta-button"><a class="button <?php
echo $button_style;
?>
" href="<?php
echo $button_link;
?>
"><?php
echo $button_text;
?>
</a></li>
<?php
}
?>
</ul>
</div>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:sialaweb,项目名称:Euroimpacto-theme,代码行数:54,代码来源:elements.php
示例4: message_box
function message_box($atts, $content = null)
{
extract(shortcode_atts(array('bg' => '#333', 'text_color' => 'light'), $atts));
$color = "light";
if ($text_color == 'light') {
$color = "dark";
}
$background = "";
$background_color = "";
if (strpos($bg, 'http://') !== false) {
$background = $bg;
} elseif (strpos($bg, '#') !== false) {
$background_color = 'background-color:' . $bg . '!important';
} else {
$bg = wp_get_attachment_image_src($bg, 'large');
$background = $bg[0];
}
$content = fixShortcode($content);
return '<div class="message-box ' . $color . '" style="background-image:url(' . $background . ');' . $background_color . '"><div class="row"><div class="large-12 columns"><div class="inner">' . $content . '</div></div></div></div><!-- .message-box -->';
}
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:20,代码来源:messages.php
示例5: featured_box
function featured_box($atts, $content = null)
{
$sliderrandomid = rand();
extract(shortcode_atts(array('title' => '', 'title_small' => '', 'img' => '', 'img_width' => '', 'pos' => '', 'link' => '', 'tooltip' => ''), $atts));
ob_start();
?>
<div class="featured-box <?php
if ($pos) {
echo 'pos-' . $pos;
}
?>
<?php
if ($tooltip) {
echo 'tip-top';
}
?>
" data-tip="<?php
echo $tooltip;
?>
">
<div class="box-inner">
<?php
if ($link) {
echo '<a href="' . $link . '">';
}
?>
<?php
if ($img) {
?>
<img class="featured-img" src="<?php
echo $img;
?>
" alt="<?php
echo $title;
?>
" style="<?php
if ($img_width) {
echo 'max-width:' . $img_width;
}
?>
"><?php
}
?>
<?php
if ($link) {
echo '</a>';
}
?>
<?php
if ($link) {
echo '<a href="' . $link . '">';
}
?>
<h4><?php
echo $title;
?>
<span><?php
echo $title_small;
?>
</span></h4>
<?php
if ($link) {
echo '</a>';
}
?>
<p><?php
echo fixShortcode($content);
?>
</p>
</div>
</div>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:shubham79,项目名称:Jhintaak,代码行数:78,代码来源:featured_box.php
示例6: shortcode_map
//.........这里部分代码省略.........
"featureType": "road",
"stylers": [
{ "visibility": "on" },
{ "hue": "<?php
echo $color;
?>
" }
]
},
{
"stylers": [
{ "visibility": "on" },
{ "hue": "<?php
echo $color;
?>
" },
{ "saturation": -30 }
]
}
]};
var myLatlng = new google.maps.LatLng(<?php
echo $lat;
?>
, <?php
echo $long;
?>
);
var myOptions = {
zoom: <?php
echo $zoom;
?>
,
center: myLatlng,
mapTypeId: google.maps.MapTypeId.ROADMAP,
disableDefaultUI: true,
mapTypeId: 'flatsome',
draggable: true,
zoomControl: false,
panControl: false,
mapTypeControl: false,
scaleControl: false,
streetViewControl: false,
overviewMapControl: false,
scrollwheel: false,
disableDoubleClickZoom: true
}
var map = new google.maps.Map(document.getElementById("<?php
echo $mapsrandomid;
?>
"), myOptions);
var styledMapType = new google.maps.StyledMapType(styles['flatsome'], {name: 'flatsome'});
map.mapTypes.set('flatsome', styledMapType);
var marker = new google.maps.Marker({
position: myLatlng,
map: map,
title:""
});
}
google.maps.event.addDomListener(window, 'load', initialize);
google.maps.event.addDomListener(window, 'resize', initialize);
</script>
<div id="map_container">
<div id="<?php
echo $mapsrandomid;
?>
" style="height:<?php
echo $height;
?>
;"></div>
<div id="map_overlay_top"></div>
<div id="map_overlay_bottom"></div>
<?php
if ($content) {
?>
<div class="map-info">
<div class="row">
<div class="large-4 columns right">
<div class="map_inner">
<?php
echo fixShortcode($content);
?>
</div> <!-- map_inner -->
</div><!-- large-4 -->
</div><!-- row -->
</div><!-- .map-info -->
<?php
}
?>
</div>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:101,代码来源:google_maps.php
示例7: ux_product_flip
function ux_product_flip($atts, $content = null)
{
/* register script */
wp_register_script('flatsome-flip', get_template_directory_uri() . '/js/jquery.mobile.flip.js', array('jquery'), '20120202', true);
wp_enqueue_script('flatsome-flip');
global $woocommerce;
$sliderrandomid = rand();
extract(shortcode_atts(array('products' => '8', 'height' => '510px', 'cat' => ''), $atts));
ob_start();
if (!strpos($height, 'px') !== false) {
$height = $height . 'px';
}
$args = array('post_type' => 'product', 'post_status' => 'publish', 'product_cat' => $cat, 'products' => $products);
?>
<div class="flip-container" style="height:<?php
echo $height + 20;
?>
px;overflow:hidden;">
<div class="row">
<div class="large-12 columns">
<div id="flipRoot" class="flipContainer">
<?php
if ($content) {
?>
<div class="row-collapse flip-slide">
<div class="large-12 columns">
<?php
echo fixShortcode($content);
?>
</div><!-- large-6 -->
</div><!-- row -->
<?php
}
?>
<?php
$products = new WP_Query($args);
if ($products->have_posts()) {
?>
<?php
while ($products->have_posts()) {
$products->the_post();
?>
<div class="row collapse">
<?php
woocommerce_get_template_part('content', 'product-flipbook');
?>
</div>
<?php
}
// end of the loop.
?>
<?php
}
wp_reset_query();
?>
</div>
</div>
</div>
</div>
<script type="text/javascript">
jQuery(document).ready(function($) {
$("#flipRoot").flip({
height: '<?php
echo $height;
?>
',
forwardDir: 'ltor',
showPager: true,
loop: true
});
});
</script>
<style>
/* -- product flip --*/
.flipShadow{display: none!important}
.flipContainer{position:relative;-webkit-perspective:3000px;-moz-perspective:3000px;perspective:3000px;-webkit-user-select:none;-moz-user-select:none;user-select:none}
.flipContent{position:absolute;top:0;left:0;height:100%;width:100%;display:none;overflow:hidden}
.flipContent.flipCurrent{display:block}
.sliding,.slidingBg{position:absolute;overflow:hidden;z-index:1;background-color:inherit}
.flipping{background-color:inherit;-webkit-backface-visibility:hidden;-webkit-transform-style:flat;-webkit-transform:rotateY(0deg);-moz-backface-visibility:hidden;-moz-transform-style:preserve3d;-moz-transform:rotateY(0deg);backface-visibility:hidden;transform-style:preserve3d;transform:rotateY(0deg)}
.flipping.firstHalf{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;transform-origin:100% 0}
.flipping.secondHalf{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;transform-origin:0 0}
.backflipping{display:none;background-color:inherit;-webkit-backface-visibility:hidden;-webkit-transform-style:flat;-webkit-transform:rotateY(180deg);-moz-backface-visibility:hidden;-moz-transform-style:flat;-moz-transform:rotateY(180deg);backface-visibility:hidden;transform-style:flat;transform:rotateY(180deg)}
.holizontalFlipping.firstHalf{-webkit-transform-origin:100% 0;-moz-transform-origin:100% 0;transform-origin:100% 0}
.holizontalFlipping.secondHalf{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;transform-origin:0 0}
.verticalFlipping.firstHalf{-webkit-transform-origin:0 100%;-moz-transform-origin:0 100%;transform-origin:0 100%}
.verticalFlipping.secondHalf{-webkit-transform-origin:0 0;-moz-transform-origin:0 0;transform-origin:0 0}
.splitHalf{position:absolute;overflow:hidden}.splitEmpty{background-color:#333}
.flipContainer .pager{text-align:center;position:absolute;bottom:-10px;width:100%;cursor:pointer;overflow:hidden;}
.flipContainer .pager span{display: inline-block;}
.flip-slide{background: #FFF;}
.flipContainer .callout{top:20px;left:20px;}
.flipContainer .row-collapse {float:left!important;}
.flipContainer .row-collapse > .columns{padding:0!important}
.flipContainer .product-info{font-size: 80%; padding: 30px; overflow-y:auto}
.flipContainer .star-rating{margin-bottom:15px;}
.flipContainer .entry-title{padding:15px 50px 0 0;}
.flipContainer .button{margin-top: 15px;}
</style>
//.........这里部分代码省略.........
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:101,代码来源:product_flip.php
示例8: uxLightboxShortcode
function uxLightboxShortcode($atts, $content = null)
{
$sliderrandomid = rand();
ob_start();
extract(shortcode_atts(array('id' => 'enter-id-here', 'width' => '600px', 'padding' => '20px', 'auto_open' => false, 'auto_timer' => '2500', 'auto_show' => 'always'), $atts));
?>
<div id="<?php
echo $id;
?>
" class="mfp-hide mfp-content-inner lightbox-white" style="max-width:<?php
echo $width;
?>
;padding:<?php
echo $padding;
?>
">
<?php
echo fixShortcode($content);
?>
</div><!-- Lightbox-<?php
echo $id;
?>
-->
<script>
jQuery(document).ready(function($) {
<?php
if ($auto_open) {
?>
// auto open lightbox
<?php
if ($auto_show == 'always') {
?>
$.removeCookie("lightbox_<?php
echo $id;
?>
");<?php
}
?>
// run lightbox if no cookie is set
if($.cookie("lightbox_<?php
echo $id;
?>
") !== 'opened'){
// Open lightbox
setTimeout(function(){
$.magnificPopup.open({midClick: true, removalDelay: 300, items: { src: '#<?php
echo $id;
?>
', type: 'inline'}});
}, <?php
echo $auto_timer;
?>
);
// set cookie
$.cookie("lightbox_<?php
echo $id;
?>
", "opened");
}
<?php
}
?>
$('a[href="#<?php
echo $id;
?>
"]').click(function(e){
// Close openend lightboxes
var delay = 0;
if($.magnificPopup.open){
$.magnificPopup.close();
delay = 300;
}
// Start lightbox
setTimeout(function(){
$.magnificPopup.open({
midClick: true,
removalDelay: 300,
items: {
src: '#<?php
echo $id;
?>
',
type: 'inline'
}
});
}, delay);
e.preventDefault();
});
});
</script>
<?php
//.........这里部分代码省略.........
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:101,代码来源:lightbox.php
示例9: featured_box
//.........这里部分代码省略.........
if ($animated) {
echo 'scroll-animate';
}
?>
<?php
if ($icon_border) {
?>
featured-img-circle <?php
}
?>
" <?php
if ($animated) {
echo 'data-animate="' . $animated . '"';
}
?>
style="<?php
if ($img_width) {
?>
width:<?php
echo $img_width;
?>
;max-height:<?php
echo $img_width;
?>
;<?php
}
?>
<?php
if ($icon_border) {
?>
border-width:<?php
echo $icon_border;
?>
; border-color:<?php
echo $icon_color;
}
?>
"><?php
if (strpos($img, '.jpg') !== false || strpos($img, '.gif') !== false || strpos($img, '.png') !== false) {
$img = $img;
} else {
$img = wp_get_attachment_image_src($img, 'medium');
$img = $img[0];
}
if (strpos($img, '.svg') !== false) {
$svg = new SimpleXMLElement(file_get_contents($img));
$padding = "0";
if ($icon_border) {
$padding = $img_width * 0.2;
}
echo '<svg viewBox="0 0 32 32" style="width:100%; fill:' . $icon_color . '; padding:' . $padding . 'px"';
echo '<g id="' . $svg->g->attributes()->id . '"><line stroke-width="1" x1="" y1="" x2="" y2="" opacity=""></line></g>';
echo '<path d="' . $svg->path->attributes()->d . '"></path>';
echo '</svg>';
} else {
?>
<img src="<?php
echo $img;
?>
" alt="<?php
echo $title;
?>
" style="width:100%;"><?php
}
echo '</div><!-- end icon -->';
}
?>
<?php
if ($link) {
echo '</a>';
}
?>
<?php
if ($link) {
echo '<a href="' . $link . '">';
}
?>
<h4><?php
echo $title;
?>
<span><?php
echo $title_small;
?>
</span></h4>
<?php
if ($link) {
echo '</a>';
}
?>
<?php
echo fixShortcode($content);
?>
</div>
</div>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:101,代码来源:featured_box.php
示例10: shortcode_ux_slider
function shortcode_ux_slider($atts, $content = null)
{
$sliderrandomid = rand();
ob_start();
extract(shortcode_atts(array('timer' => '5000', 'bullets' => 'true', 'auto_slide' => 'true', 'arrows' => 'true', 'hide_nav' => 'false', 'nav_color' => '', 'infinitive' => 'true', 'height' => '', 'column_padding' => ''), $atts));
?>
<div class="ux_slider_wrapper">
<div id="slider_<?php
echo $sliderrandomid;
?>
" class="iosSlider default" style="<?php
if ($height) {
echo 'min-height:' . $height . '; height:' . $height;
}
?>
">
<div class="slider">
<?php
fixShortcode($content);
?>
</div>
<div class="sliderControlls <?php
echo $nav_color;
?>
<?php
if ($hide_nav == 'false') {
echo 'hide_nav';
}
?>
">
<?php
if ($arrows == 'true') {
?>
<div class="sliderNav hide-for-small">
<a href="javascript:void(0)" class="nextSlide next_<?php
echo $sliderrandomid;
?>
"><span class="icon-angle-left"></span></a>
<a href="javascript:void(0)" class="prevSlide prev_<?php
echo $sliderrandomid;
?>
"><span class="icon-angle-right"></span></a>
</div>
<?php
}
?>
<div class="sliderBullets"></div>
</div><!-- .sliderControlls -->
<div class="loading dark"><i></i><i></i><i></i><i></i></div>
</div><!-- #slider -->
<script type="text/javascript">
(function($){
$(window).load(function(){
$('#slider_<?php
echo $sliderrandomid;
?>
').find('br').remove();
/* install slider */
$('#slider_<?php
echo $sliderrandomid;
?>
').iosSlider({
snapToChildren: true,
desktopClickDrag: true,
snapFrictionCoefficient: 0.8,
autoSlideTransTimer: 500,
horizontalSlideLockThreshold:3,
slideStartVelocityThreshold:3,
infiniteSlider:<?php
echo $infinitive;
?>
,
autoSlide: <?php
echo $auto_slide;
?>
,
autoSlideTimer: <?php
echo $timer;
?>
,
navPrevSelector: $('.next_<?php
echo $sliderrandomid;
?>
'),
navNextSelector: $('.prev_<?php
echo $sliderrandomid;
?>
'),
onSliderLoaded: startSlider,
onSlideChange: slideChange,
onSliderResize: slideResize,
});
function slideChange(args) {
$(args.sliderContainerObject).find('.inner').each(function(){
//.........这里部分代码省略.........
开发者ID:shubham79,项目名称:Jhintaak,代码行数:101,代码来源:slider.php
示例11: ux_product_flip
function ux_product_flip($atts, $content = null)
{
global $woocommerce;
$sliderrandomid = rand();
extract(shortcode_atts(array('products' => '8', 'cat' => ''), $atts));
ob_start();
$args = array('post_type' => 'product', 'post_status' => 'publish', 'product_cat' => $cat, 'products' => $products);
?>
<div class="row">
<div class="large-12 columns flip-container">
<div class="flipContainer js-flickity slider-nav-circle slider-nav-slide-in"
data-flickity-options='{
"cellAlign": "center",
"wrapAround": true,
"percentPosition": true,
"imagesLoaded": true,
"pageDots": true,
"contain": true
}'>
<?php
if ($content) {
?>
<div class="row collapse">
<div class="large-12 columns">
<?php
echo fixShortcode($content);
?>
</div><!-- large-6 -->
</div><!-- row -->
<?php
}
?>
<?php
$products = new WP_Query($args);
if ($products->have_posts()) {
?>
<?php
while ($products->have_posts()) {
$products->the_post();
?>
<?php
woocommerce_get_template_part('content', 'product-flipbook');
?>
<?php
}
// end of the loop.
?>
<?php
}
wp_reset_query();
?>
</div>
</div>
</div><!-- row -->
<style>
.flipContainer{
background: #FFF;
box-shadow: 1px 1px 10px 0px rgba(0,0,0,.2);
}
.flipContainer .featured-product{
margin-bottom: 0;
}
.flip-slide .product-info{
padding: 10%;
}
.flip-slide .product_meta{
margin-bottom: 15px;
}
</style>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:79,代码来源:product_flip.php
示例12: ux_banner_grid
//.........这里部分代码省略.........
if ($grid == '1') {
$g_total = '5';
$g = array('height1' => $tall_height, 'span1' => 'large-6 small-12', 'height2' => $tall_height, 'span2' => 'large-3 small-6', 'height3' => $small_height, 'span3' => 'large-3 small-6', 'height4' => $small_height, 'span4' => 'large-3 small-6', 'height5' => $small_height, 'span5' => 'large-3 small-6');
}
if ($grid == '2') {
$g_total = '4';
$g = array('height1' => $tall_height, 'span1' => 'large-12 small-12', 'height2' => $smallest_height, 'span2' => 'large-4 small-12', 'height3' => $smallest_height, 'span3' => 'large-4 small-12', 'height4' => $smallest_height, 'span4' => 'large-4 small-12');
}
if ($grid == '3') {
$g_total = '3';
$g = array('height1' => $tall_height, 'span1' => 'large-6 small-12', 'height2' => $small_height, 'span2' => 'large-6 small-6', 'height3' => $small_height, 'span3' => 'large-3 small-6');
}
if ($grid == '4') {
$g_total = '1';
$g = array('height1' => $tall_height, 'span1' => 'large-3 small-6');
}
if ($grid == '5') {
$g_total = '1';
$g = array('height1' => $tall_height, 'span1' => 'large-4 small-6');
}
if ($grid == '6') {
$g_total = '3';
$g = array('height1' => $tall_height, 'span1' => 'large-9 small-12', 'height2' => $small_height, 'span2' => 'large-3 small-6', 'height3' => $small_height, 'span3' => 'large-3 small-6');
}
if ($grid == '7') {
$g_total = '3';
$g = array('height1' => $tall_height, 'span1' => 'large-3 small-6', 'height2' => $tall_height, 'span2' => 'large-6 small-12', 'height3' => $small_height, 'span3' => 'large-3 small-6');
}
if ($grid == '8') {
$g_total = '3';
$g = array('height1' => $tall_height, 'span1' => 'large-3 small-6', 'height2' => $tall_height, 'span2' => 'large-6 small-12', 'height3' => $tall_height, 'span3' => 'large-3 small-6');
}
if ($grid == '9') {
$g_total = '2';
$g = array('height1' => $tall_height, 'span1' => 'large-6 small-12', 'height2' => $small_height, 'span2' => 'large-3 small-6');
}
if ($grid == '10') {
$g_total = '5';
$g = array('height1' => $tall_height, 'span1' => 'large-6 small-12', 'height2' => $smallest_height, 'span2' => 'large-6 small-12', 'height3' => $smallest_height, 'span3' => 'large-3 small-12', 'height4' => $smallest_height, 'span4' => 'large-3 small-12', 'height5' => $smallest_height, 'span5' => 'large-6 small-12');
}
if ($grid == '11') {
$g_total = '5';
$g = array('height1' => $less_tall_height, 'span1' => 'large-6 small-12', 'height2' => $less_tall_height, 'span2' => 'large-3 small-12', 'height3' => $tall_height, 'span3' => 'large-3 small-12', 'height4' => $smallest_height, 'span4' => 'large-3 small-12', 'height5' => $smallest_height, 'span5' => 'large-6 small-12');
}
if ($grid == '12') {
$g_total = '6';
$g = array('height1' => $smallest_height, 'span1' => 'large-8 small-12', 'height2' => $smallest_height, 'span2' => 'large-4 small-12', 'height3' => $smallest_height, 'span3' => 'large-4 small-12', 'height4' => $smallest_height, 'span4' => 'large-8 small-12', 'height5' => $smallest_height, 'span5' => 'large-8 small-12', 'height6' => $smallest_height, 'span6' => 'large-4 small-12');
}
if ($grid == '13') {
$g_total = '6';
$g = array('height1' => $less_tall_height, 'span1' => 'large-6 small-12', 'height2' => $small_height, 'span2' => 'large-3 small-12', 'height3' => $tall_height, 'span3' => 'large-3 small-12', 'height4' => $smallest_height, 'span4' => 'large-6 small-12', 'height5' => $small_height, 'span5' => 'large-3 small-12', 'height6' => $smallest_height, 'span6' => 'large-6 small-12');
}
if ($grid == '14') {
$g_total = '6';
$g = array('height1' => $smallest_height, 'span1' => 'large-9 small-12', 'height2' => $tall_height, 'span2' => 'large-3 small-12', 'height3' => $less_tall_height, 'span3' => 'large-3 small-12', 'height4' => $smallest_height, 'span4' => 'large-3 small-12', 'height5' => $smallest_height, 'span5' => 'large-3 small-12', 'height6' => $smallest_height, 'span6' => 'large-6 small-12');
}
// Build grid
foreach ($matches[0] as $shortcode) {
$grid_class = '';
if ($g['height' . $id] < '200px') {
$grid_class = 'grid-small-height';
} else {
if ($g['height' . $id] < '300px') {
$grid_class = 'grid-medium-height';
}
}
echo '<div class="columns ux-grid-column ' . $grid_class . ' ' . $g['span' . $id] . '" style="height:' . $g['height' . $id] . '"><div class="column-inner">';
echo fixShortcode($shortcode);
echo '</div></div>';
if ($id < $g_total) {
$id++;
}
}
}
} else {
echo fixShortcode($content);
}
?>
</div>
</div>
</div>
<script>
jQuery(document).ready(function ($) {
var $container = $("#banner_grid_<?php
echo $shortcode_id;
?>
.ux_banner-grid");
$container.packery({
itemSelector: ".columns",
gutter: 0
});
});
</script>
</div><!-- #banner-grid -->
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:101,代码来源:banner_grid.php
示例13: ux_accordion_item
function ux_accordion_item($atts, $content = null, $code)
{
extract(shortcode_atts(array('title' => ''), $atts));
return '<div class="accordion-title"><a href="#">' . $title . '</a></div><div class="accordion-inner">' . fixShortcode($content) . '</div>';
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:5,代码来源:accordion.php
示例14: team_member
//.........这里部分代码省略.........
<?php
}
?>
<?php
if ($twitter) {
?>
<a href="<?php
echo $twitter;
?>
" target="_blank" class="icon icon_twitter tip-top" title="<?php
echo $twitter;
?>
"><span class="icon-twitter"></span></a>
<?php
}
?>
<?php
if ($email) {
?>
<a href="mailto:<?php
echo $email;
?>
" target="_blank" class="icon icon_email tip-top" title="<?php
echo $email;
?>
"><span class="icon-envelop"></span></a>
<?php
}
?>
<?php
if ($pinterest) {
?>
<a href="<?php
echo $pinterest;
?>
" target="_blank" class="icon icon_pintrest tip-top" title="<?php
echo $pinterest;
?>
"><span class="icon-pinterest"></span></a>
<?php
}
?>
<?php
if ($instagram) {
?>
<a href="<?php
echo $instagram;
?>
" target="_blank" class="icon icon_instagram tip-top" title="<?php
echo $instagram;
?>
"><span class="icon-instagram"></span></a>
<?php
}
?>
<?php
if ($linkedin) {
?>
<a href="<?php
echo $linkedin;
?>
" target="_blank" class="icon icon_linkedin tip-top" title="<?php
echo $linkedin;
?>
"><span class="icon-linkedin"></span></a>
<?php
}
?>
</div>
</div>
<p><?php
if ($style != 'text-overlay') {
echo fixShortcode($content);
}
?>
</p>
</div><!-- .ux-box-text-overlay -->
</div>
</div>
</div>
<?php
if ($style == 'text-overlay') {
?>
<div class="small-font" style="margin-top:15px;"><?php
echo fixShortcode($content);
?>
</div>
<?php
}
?>
<?php
$content = ob_get_contents();
ob_end_clean();
return $content;
}
开发者ID:bqevin,项目名称:wp-shopeasy,代码行数:101,代码来源:team_members.php
示例15: uxbannerShortcode
//.........这里部分代码省略.........
<div class="inner <?php
echo $text_pos;
?>
<?php
echo $textalign;
?>
<?php
if ($text_bg) {
echo 'text-boxed';
}
?>
" style="width:<?php
echo $text_width;
?>
;">
<div class="inner-wrap <?php
echo $animated;
?>
" data-animate="<?php
echo $animation;
?>
" style="<?php
if ($text_bg) {
echo 'background-color:' . ux_hex2rgba($text_bg, $text_bg_opacity) . ';';
}
?>
<?php
if ($text_bg) {
echo 'padding:' . $padding;
}
?>
">
<?php
echo fixShortcode($content);
?>
</div>
</div>
</div>
<?php
echo $end_link;
?>
<?php
if ($mob_height || $tablet_height || $animation_duration) {
?>
<style>
<?php
if ($tablet_height) {
?>
@media only screen and (max-width: 768px) { #banner_<?php
echo $bannerid;
?>
{ height:<?php
echo $tablet_height;
?>
!important} } <?php
}
// mob height
?>
<?php
if ($mob_height) {
?>
@media only screen and (max-width: 480px) { #banner_<?php
echo $bannerid;
?>
{ height:<?php
echo $mob_height;
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:67,代码来源:banners.php
示例16: backgroundSlideShortcode
//.........这里部分代码省略.........
?>
<?php
if ($img && $img_pos != 'bottom') {
?>
<div class="ux-section-img <?php
echo $img_pos;
?>
" style="width:<?php
echo $img_width;
?>
; background-image: url('<?php
echo $img;
?>
');<?php
if ($img_margin) {
echo 'margin:' . $img_margin . ' 0;';
}
?>
"><img src="<?php
echo $img;
?>
"></div><?php
}
?>
<div class="ux-section-content<?php
echo $text_parallax_class;
echo $text_parallax_class;
?>
"<?php
echo $parallax_text;
?>
><?php
echo fixShortcode($content);
?>
</div>
<?php
if ($img && $img_pos == 'bottom') {
?>
<div class="ux-section-img <?php
echo $img_pos;
?>
" style="width:<?php
echo $img_width;
?>
; background-image: url('<?php
echo $img;
?>
');"><img src="<?php
echo $img;
?>
"></div><?php
}
?>
<?php
if ($video_mp4 || $video_webm || $video_ogv) {
?>
<video class="ux-banner-video hide-for-small" poster="<?php
echo $background;
?>
" preload="auto" autoplay="" loop="loop" muted="muted">
<source src="<?php
echo $video_mp4;
?>
" type="video/mp4">
开发者ID:bachhuong,项目名称:dains-development,代码行数:67,代码来源:background_slide.php
示例17: colShortcode
//.........这里部分代码省略.........
case "2/3":
$span = '8';
break;
case "1/2":
$span = '6';
break;
case "1/6":
$span = '2';
break;
case "2/6":
$span = '4';
break;
case "3/6":
$span = '6';
break;
case "4/6":
$span = '8';
break;
case "5/6":
$span = '10';
break;
case "1/12":
$span = '1';
break;
case "2/12":
$span = '2';
break;
case "3/12":
$span = '3';
break;
case "4/12":
$span = '4';
break;
case "5/12":
$span = '5';
break;
case "6/12":
$span = '6';
break;
case "7/12":
$span = '7';
break;
case "8/12":
$span = '8';
break;
case "9/12":
$span = '9';
break;
case "10/12":
$span = '10';
break;
case "11/12":
$span = '11';
break;
}
// SCROLL HTML
$scroll = '';
$scroll_html = '';
if ($animate) {
$scroll = 'scroll-animate';
$scroll_html = 'data-animate="' . $animate . '"';
}
if ($align) {
$align = ' text-' . $align . ' ';
}
// DELAY HTML
$delay_html = '';
if ($delay) {
$delay_html = 'style="-webkit-animation-delay: ' . $delay . ';animation-delay: ' . $delay . ';-moz-animation-delay: ' . $delay . ';"';
}
// HOVER HTML
if ($hover) {
$hover = 'col_hover_' . $hover;
}
// PADDING HTML
if ($padding) {
$padding = 'style="padding:' . $padding . '"';
}
// TOOLTIP
$tooltip_class = '';
if ($tooltip) {
$tooltip = 'title="' . $tooltip . '"';
$tooltip_class = 'tip-top';
}
// Background
$bg_class = '';
if ($bg) {
$bg = 'background-color:' . $bg;
$bg_class = 'col-bg';
}
// Parallax
$parallax_html = '';
$text_parallax_class = '';
if ($parallax) {
$text_parallax_class = ' parallax_text';
$parallax_html = ' data-velocity="-0.' . $parallax . '"';
}
$column = '<div class="small-' . $small . '' . $align . ' ' . $bg_class . ' ' . $tooltip_class . ' ' . $class . ' large-' . $span . ' ' . $hover . ' columns ' . $scroll . '" ' . $tooltip . ' ' . $scroll_html . ' ' . $delay_html . '><div class="column-inner' . $text_parallax_class . '" ' . $parallax_html . ' ' . $padding . '>' . $content . '</div></div>';
return fixShortcode($column);
}
开发者ID:javipaur,项目名称:TiendaVirtual,代码行数:101,代码来源:grid.php
示例18: ux_product_categories_grid
-
librespeed/speedtest: Self-hosted Speedtest for HTML5 and more. Easy setup, exam
阅读:1291|2022-08-30
-
avehtari/BDA_m_demos: Bayesian Data Analysis demos for Matlab/Octave
阅读:1205|2022-08-17
-
女人怀孕后,为了有一个健康聪明的宝宝,经历各种体检、筛查。其实这些体检和筛查中的
阅读:1002|2022-11-06
-
Vesta v1.0.0-5 was discovered to contain a cross-site scripting (XSS) vulnerabil
阅读:533|2022-07-29
-
medfreeman/markdown-it-toc-and-anchor: markdown-it plugin to add a toc and ancho
阅读:1401|2022-08-18
-
sslcommerz/SSLCommerz-Laravel: SSLCOMMERZ is a bangladeshi payment gateway provi
阅读:917|2022-08-13
-
qiangxi/CheckUpdateLibrary: Android检查更新库
阅读:881|2022-08-15
-
sydney0zq/covid-19-detection: The implementation of A Weakly-supervised Framewor
阅读:518|2022-08-16
-
离中国最远的国家是阿根廷。从太平洋直线计算,即往东线走,北京到阿根廷的布宜诺斯艾
阅读:669|2022-11-06
-
这个文章不会说具体0到1的代码流程,我会着重讲几个问题的解决 准备以下依赖 amp;quot
阅读:643|2022-07-18
|
请发表评论