instinctual,
Thanks- but no cigar. I guess the "k" is your item, but even replacing that with my "item" doesn't pull anything. There must be a way as the dropdown is loaded with variantid's but I can't see to pull the # out to use in in my image swap a href. Ideas?
Thanks for your help. Just in case, here's the code I am trying to use to include the variantid. You can see it in the <a href>:
Code:
{assign var="image_counter" value=0}
{section name=swatch loop=$variants}
{if $image_counter is div by 2}
<tr>
{assign var="image_counter" value=0}
{/if}
{math equation="x+1" x=$image_counter assign="image_counter" }
<td width="20" valign="top"></td>
{foreach item=item key=key from=$variants[swatch].options}
<td width="16" height="16" valign="top" class="{$item.option_name|replace:" ":""|replace:"/":""|replace:".":""}">[img]{$ImagesDir}/resources/dot_clear.gif[/img]</td>
<td valign="top">
{***
<A HREF="javascript:swapImage('image.php?productid={$product.productid}&variantid={$variants[v].variantid}');">
***}
{$item.option_name}</td>
{/foreach}
{capture name=image_index}
{math equation="index+x+1" index=$image_counter x=2}
{/capture}
{if $image_counter is div by 2 }
</tr>
{/if}
{/section}
Thanks, Mike