Пример #1
0
    ?>
	<div class="columns">
		<ul>
			<?php 
    foreach ($brands as $brand) {
        ?>
				<li class="col-1-<?php 
        echo $columns;
        ?>
">
					<figure class="full-width">
						<a href="<?php 
        echo get_term_link($brand->slug, 'product_brand');
        ?>
" <?php 
        Everything::imageAttrs('a', array('border' => false, 'hover' => ''));
        ?>
>
							<?php 
        if ($thumbnail_id = get_woocommerce_term_meta($brand->term_id, 'thumbnail_id', true)) {
            echo wp_get_attachment_image($thumbnail_id, $size);
        } else {
            echo woocommerce_placeholder_img();
        }
        ?>
						</a>
					</figure>
				</li>
			<?php 
    }
    ?>
Пример #2
0
    foreach (WC()->cart->get_cart() as $cart_item_key => $cart_item) {
        $_product = apply_filters('woocommerce_cart_item_product', $cart_item['data'], $cart_item, $cart_item_key);
        $product_id = apply_filters('woocommerce_cart_item_product_id', $cart_item['product_id'], $cart_item, $cart_item_key);
        if ($_product && $_product->exists() && $cart_item['quantity'] > 0 && apply_filters('woocommerce_widget_cart_item_visible', true, $cart_item, $cart_item_key)) {
            $product_name = apply_filters('woocommerce_cart_item_name', $_product->get_title(), $cart_item, $cart_item_key);
            $thumbnail = apply_filters('woocommerce_cart_item_thumbnail', $_product->get_image('post-thumbnail-mini'), $cart_item, $cart_item_key);
            $product_price = apply_filters('woocommerce_cart_item_price', WC()->cart->get_product_price($_product), $cart_item, $cart_item_key);
            ?>

			<li>
				<figure class="alignright fixed">
					<a href="<?php 
            echo get_permalink($product_id);
            ?>
" <?php 
            Everything::imageAttrs('a', array('border' => true, 'hover' => '', 'fanbcybox' => false));
            ?>
>
						<?php 
            echo $thumbnail;
            ?>
					</a>
				</figure>
				<h3>
					<a href="<?php 
            echo get_permalink($product_id);
            ?>
">
						<?php 
            echo $product_name;
            ?>
Пример #3
0
<?php

/**
 * @package    WooCommerce/Templates
 * @subpackage Everything
 * @since      1.0
 */
// -----------------------------------------------------------------------------
if (!defined('ABSPATH')) {
    exit;
}
// -----------------------------------------------------------------------------
global $woocommerce;
if ($thumbnail) {
    ?>
		<figure class="full-width featured">
			<div <?php 
    Everything::imageAttrs('div', array('border' => false));
    ?>
>
				<img src="<?php 
    echo $thumbnail;
    ?>
" />
			</div>
		</figure>
	<?php 
}
echo wpautop(wptexturize(term_description()));
Пример #4
0
    if (!($url = wp_get_attachment_url($attachment_id))) {
        continue;
    }
    ?>
			<li class="col-1-<?php 
    echo $columns;
    ?>
">
				<figure class="full-width">
					<a href="<?php 
    echo $url;
    ?>
" data-fancybox-title="<?php 
    echo esc_attr(Everything::woocommerceGetThumbnailCaption($attachment_id));
    ?>
" data-fancybox-group="product-gallery" <?php 
    Everything::imageAttrs('a');
    ?>
>
						<?php 
    echo wp_get_attachment_image($attachment_id, apply_filters('single_product_small_thumbnail_size', 'shop_thumbnail'));
    // missing filter: woocommerce_single_product_image_thumbnail_html
    ?>
					</a>
				</figure>
			</li>
		<?php 
}
?>
	</ul>
</div>
        the_ID();
        ?>
" <?php 
        post_class(array('portfolio-item', 'bordered'));
        // todo: bordered - zalezne od ustawien
        ?>
>
						<?php 
        if (has_post_thumbnail()) {
            ?>
							<figure class="thumbnail featured full-width">
								<a href="<?php 
            the_permalink();
            ?>
" <?php 
            Everything::imageAttrs('a', array('border' => false, 'fancybox' => false));
            ?>
>
									<?php 
            the_post_thumbnail('auto');
            ?>
								</a>
							</figure>
						<?php 
        }
        ?>
						<?php 
        if (Everything::to('portfolio/archive/title')) {
            ?>
							<h3><a href="<?php 
            the_permalink();
Пример #6
0
<?php 
get_header();
?>

<?php 
if (have_posts()) {
    the_post();
    ?>

	<section class="section">
		<?php 
    Everything::title();
    ?>
		<figure class="full-width">
			<div <?php 
    Everything::imageAttrs('div');
    ?>
>
				<?php 
    echo wp_get_attachment_image(get_the_ID(), 'full-width');
    ?>
			</div>
			<?php 
    if (has_excerpt()) {
        ?>
				<figcaption><?php 
        the_excerpt();
        ?>
</figcaption>
			<?php 
    }