{$_head_prefix = "og: http://ogp.me/ns# fb: http://ogp.me/ns/fb# product: http://ogp.me/ns/product#"} {$wa->globals("headPrefix", $_head_prefix)} {function name="_render_sku_features" _features=[]} {foreach $_features as $_feature_id => $_feature_value} {$_true_params = ["weight", "brand", "model", "width", "height", "depth", "color", "manufacturer"]} {$_is_good_param = ($_feature_id|in_array:$_true_params)} {$_itemprop = ""} {if $_is_good_param}{$_itemprop = $_feature_id}{/if} {$_feature = ifset($sku_features, $_feature_id, null)} {if $_feature && $_feature.type == 'divider'} {elseif $_feature} {/if} {/foreach}
{$_feature.name|escape}
{$_feature.name|escape} {if is_array($_feature_value)} {if $_feature.type == 'color'} {implode('
', $_feature_value)} {else} {implode(', ', $_feature_value)} {/if} {else} {$_feature_value} {/if}
{/function} {$_skus_features_html = []} {foreach $product.skus as $_sku} {if !empty($_sku.features)} {capture assign="_sku_features_html"}{_render_sku_features _features=$_sku.features}{/capture} {$_skus_features_html[$_sku.id] = $_sku_features_html} {/if} {/foreach}

{$product.name|escape} {if !empty($product.rating) && $product.rating > 0} {$wa->shop->ratingHtml($product.rating, 16)} {if !empty($reviews_total_count)} {/if} {/if}

{include file="product.cart.html" inline} {if $theme_settings.compare_products}
[`Add to comparison table`] [`Remove from comparison table`] [`Compare`] {count($compare)}
{/if} {* @event frontend_product.%plugin_id%.cart *} {foreach $frontend_product as $_}{$_.cart}{/foreach}
{* @event frontend_product.%plugin_id%.block_aux *} {if !empty($frontend_product)}
{foreach $frontend_product as $_}{$_.block_aux}{/foreach}
{/if}
{$video = $product->video} {if $video}
{if !empty($video.images[0])} {$_thumb = $video.images[0]} {$_absolute_thumb_uri = "{$wa->url(true)}{$_thumb|substr:1}"} {/if}
{/if} {if $product.images || $video} {/if} {* @event frontend_product.%plugin_id%.block *} {foreach $frontend_product as $_}{$_.block}{/foreach} {if $product.description}
{$product.description}
{/if}
{if !empty($_skus_features_html[$product.sku_id])}{$_skus_features_html[$product.sku_id]}{/if}
{if $product.categories}

[`Categories`]: {foreach $product.categories as $c}{if $c.status} {$c.name|escape} {/if}{/foreach}

{/if} {if $product.tags}

[`Tags`]: {foreach $product.tags as $t} {$t} {/foreach}

{/if}

{sprintf('[`%s reviews`]', $product.name|escape)}

{if !empty($rates)}

[`Average customer rating:`] {$wa->shop->ratingHtml($product.rating, 16)} ({$reviews_total_count}) {if $product.rating > 0}{sprintf('[`%s out of 5 stars`]', $product.rating)}{/if}

{$_total_count = 0} {foreach $rates as $_rate => $_count} {$_total_count = $_total_count + $_count} {/foreach} {* foreach $rates as $_rate => $_count *} {for $i = 5 to 0 step -1} {if empty($rates[$i]) || !$rates[$i]}{$_count = 0}{else}{$_count = $rates[$i]}{/if} {if $i || $_count} {/if} {/for}
{$_count}
{for $j=1 to $i}{forelse}[`no rate`]{/for}
{/if}
    {foreach $reviews as $review}
  • {include file="review.html" reply_allowed=false inline}
  • {/foreach}
{if !$reviews}

{sprintf('[`Be the first to write a review of this product!`]', 'reviews/')}

{else} {sprintf(_w( 'Read all %d review on %s', 'Read all %d reviews on %s', $reviews_total_count, false ), 'reviews/', $reviews_total_count, $product.name|escape) } {/if}
{$upselling = $product->upSelling(12)} {$crossselling = $product->crossSelling(12)} {if $upselling || $crossselling}
{if $crossselling} {/if} {if $upselling} {/if}
{/if}