{* supreme 1.7.3 *}

[`Compare products`]{if count($products)}{/if}

{if count($products)} {$no_symbol = "—"}
[`All features`] [`Different`]
{$td_width = round((100-25)/max(1,count($products)))} {$product_names = ''} {foreach $products as $p name=product_names} {/foreach} {foreach $products as $p} {/foreach} {if !empty($theme_settings.product_hidden_features)} {$hidden_feature_ids = str_replace(" ","",$theme_settings.product_hidden_features)} {if !empty($hidden_feature_ids)} {$hidden_feature_ids = explode(",",$hidden_feature_ids)} {$hidden_features = $hidden_feature_ids} {else} {$hidden_features = false} {/if} {/if} {foreach $features as $f_id=>$f} {$is_hidden_feature = !empty($hidden_features) && in_array($f_id, $hidden_features)} {$has_hidden_feature_prefix = !empty($theme_settings.product_hidden_feature_prefix) && strpos($f_id, $theme_settings.product_hidden_feature_prefix) === 0} {if !$is_hidden_feature && !$has_hidden_feature_prefix} {if $f.type == 'divider'} {else} {foreach $products as $p} {/foreach} {/if} {/if} {/foreach}
{$p.name}
1}data-url="{$wa->getUrl('/frontend/product/', ['product_url' => $p.url])}?quick_view=1"{/if} method="post" action="/cart/add/">
{$product_names = $product_names|cat:($p.name)} {if !$smarty.foreach.product_names.last}{$product_names = $product_names|cat:', '}{/if}
[`Price`] {shop_currency_html($p.price)}
{$f.name}
{$f.name} {if isset($p.features[$f_id])} {if is_array($p.features[$f_id])} {implode('
', $p.features[$f_id])} {else} {$p.features[$f_id]} {/if} {else} {$no_symbol} {/if}
{$wa->title( sprintf('[`Compare %s`]', $product_names) )}
{else}

[`Product comparison list is empty.`]

{$wa->title("[`Compare products`]")} {/if}