コード例 #1
0
        $class_column = 'col-lg-4 col-md-4 col-sm-6 col-xs-12';
        break;
    case '2':
        $class_column = 'col-lg-6 col-md-6 col-sm-6 col-xs-12';
        break;
    default:
        $class_column = 'col-lg-12 col-md-12 col-sm-12 col-xs-12';
        break;
}
if ($type == '') {
    return;
}
global $woocommerce;
$_id = wpo_makeid();
$_count = 1;
$loop = wpo_woocommerce_query($type, $number);
if ($loop->have_posts()) {
    ?>
	
	<div class="widget widget-products products">
		<?php 
    if ($title != '') {
        ?>
			<h3 class="widget-title"><?php 
        echo esc_html($title);
        ?>
</h3>			
		<?php 
    }
    ?>
		<?php 
コード例 #2
0
    <?php 
/**
 * $Desc
 *
 * @version    $Id$
 * @package    wpbase
 * @author     WPOpal  Team <wpopal@gmail.com, support@wpopal.com>
 * @copyright  Copyright (C) 2014 wpopal.com. All Rights Reserved.
 * @license    GNU/GPL v2 or later http://www.gnu.org/licenses/gpl-2.0.html
 *
 * @website  http://www.wpopal.com
 * @support  http://www.wpopal.com/support/forum.html
 */
extract(shortcode_atts(array('title' => '', 'columns_count' => '2'), $atts));
$deals = array();
$p_deals = wpo_woocommerce_query('deals')->posts;
$_id = wpo_makeid();
$_count = 1;
switch ($columns_count) {
    case '4':
        $class_column = 'col-sm-6 col-md-3';
        break;
    case '3':
        $class_column = 'col-sm-4';
        break;
    case '2':
        $class_column = 'col-sm-6';
        break;
    default:
        $class_column = 'col-sm-12';
        break;
コード例 #3
0
ファイル: wpo_productcategory.php プロジェクト: jimmitjoo/mnh
    case '3':
        $class_column = 'col-md-4 col-sm-12';
        break;
    case '2':
        $class_column = 'col-md-6 col-sm-6';
        break;
    default:
        $class_column = 'col-md-12 col-sm-12';
        break;
}
$_id = wpo_makeid();
if ($category == '') {
    return;
}
$_count = 1;
$loop = wpo_woocommerce_query('', $number, $category);
?>
<div class="widget widget-products <?php 
echo $el_class != '' ? ' ' . $el_class : '';
?>
">
	<?php 
if ($title) {
    ?>
		<h3 class="widget-title visual-title">
	       <span><span><?php 
    echo esc_attr($title);
    ?>
</span></span>
		</h3>
	<?php 
コード例 #4
0
			<?php 
    $__count = 0;
    ?>
			<?php 
    foreach ($list_query as $key => $li) {
        ?>
				<div class="tab-pane<?php 
        echo $__count == 0 ? ' active' : '';
        ?>
" id="<?php 
        echo esc_attr($key) . '-' . esc_attr($_id);
        ?>
">
					<div class="wpo-content">
							<?php 
        $loop = wpo_woocommerce_query($key, $number);
        if ($number == -1) {
            $_post_per_page = $loop->found_posts;
        } else {
            $_post_per_page = $number;
        }
        if ($loop->have_posts()) {
            wc_get_template('widget-products/' . $style . '.php', array('loop' => $loop, 'columns_count' => $columns_count, 'class_column' => $class_column, 'posts_per_page' => $number));
        }
        ?>
					</div>

				

				</div>
				<?php