yanknudtskov of YanCo ApS
5/21/2017 - 10:05 AM

Modifying WooCommerce Shop Image size

Modifying WooCommerce Shop Image size

<?php

/**
	 * Modify Product Image HTML
	 */

	function yanco_avia_woocommerce_thumbnail($asdf)
	{
		global $product, $avia_config;
		$rating = $product->get_rating_html(); //get rating
		$ribbon_html = '';

		$id = get_the_ID();
		$size = 'large';

		$ribbon_html = yancoGetRibbonHtml('acf_woocommerce_product_ribbon_color', $product);

		echo "<div class='thumbnail_container'>";
			echo $ribbon_html;
			echo avia_woocommerce_gallery_first_thumbnail( $id , $size);
			echo get_the_post_thumbnail( $id , $size );
			if(!empty($rating)) echo "<span class='rating_container'>".$rating."</span>";
			if($product->product_type == 'simple') echo "<span class='cart-loading'></span>";
		echo "</div>";
	}