View Single Post
  #6  
Old 09-27-2006, 08:13 AM
  dalmuti's Avatar 
dalmuti dalmuti is offline
 

eXpert
  
Join Date: Oct 2004
Location: Kansas
Posts: 343
 

Default Re: Product Variant Thumbnails - How To Display?

Just in case someone has the same idea....here is the code to display variant thumbnails in rows:

Quote:
{if $variants ne ""}
<table cellpadding="0" cellspacing="0" border="0">
<tr>
{foreach name=variants from=$variants item=var}
<td width="160">
<a href="product.php?productid={$var.productid}">
<img src="{$var.image_url}" width="150" height="150"></a>
<br />
{foreach from=$var.options item=o}
<b>{$o.option_name}</b>
{/foreach}
<br /><br />
</td>
{if $smarty.foreach.variants.iteration is div by 3}
</tr>
<tr>
{elseif not $smarty.foreach.variants.last}
<td></td>
{/if}
{/foreach}
</tr>
</table>
{/if}
__________________
Louise

Studio 57 Designs - X-Cart Customization
Providing X-Cart Services since 2004
Hottest Blog Directory - Submit Your Blog for a Free Listing
Reply With Quote