Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Variant image in minicart

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 09-24-2013, 11:39 AM
  websupport's Avatar 
websupport websupport is offline
 

Advanced Member
  
Join Date: May 2005
Posts: 32
 

Default Variant image in minicart

Okay I need the variant image to show in the minicart instead of the default image. Here is the code I have right now:


<li{interline index=$smarty.foreach.products.index total=$list_length}>
<div class="minicart-item">
<table>
<tr>
<td>
<a href="{$xcart_web_dir}/product.php?productid={$product.productid}"><img src="{$xcart_web_dir}/{$product.image_path}" style="width: 70px;"></a>
</td>
<td style="padding-left: 5px;">
<table>
<tr>
<td style="width: 200px; border-bottom: 1px solid #c4c4c4;">
<a href="{$xcart_web_dir}/product.php?productid={$product.productid}" class="minicart-lnk" style="text-decoration: none; text-transform: uppercase; line-height: 10px; color: #9e9e9e; font-size: 11px; font-family: minion pro;">{$product.product}</a>
<br />

{if $active_modules.Product_Configurator and $product.product_type eq "C"}
{assign var="price" value=$product.pconf_display_price}
{else}
{assign var="price" value=$product.display_price}
{/if}

<div class="price-row" style="margin-top: 0px; padding-bottom: 5px;">
{*
{if $active_modules.Egoods and $product.distribution}

<span class="quantity" style="color: #9e9e9e;">
1
<input type="hidden" name="productindexes[{$product.cartid}]" value="1" />
</span>

{else}

<input type="text" name="productindexes[{$product.cartid}]" value="{$product.amount}" class="quantity" />
{/if}
x
<span class="price" style="color: #9e9e9e;">{currency value=$price}</span>
= *}
<span class="total" style="color: #9e9e9e;">{multi x=$price y=$product.amount assign=unformatted}{currency value=$unformatted}</span>



</div>
</td>
<td style="vertical-align: top; padding-left: 5px;">
<a href="{$xcart_web_dir}/cart.php?mode=delete&amp;productindex={$product.ca rtid}" class="delete" title="{$lng.lbl_delete_item|escape}"><img src="{$ImagesDir}/spacer.gif" alt="" /></a>
</td>
</tr>
<tr>
<td style="padding-top: 5px;">
<ul>
{foreach from=$product.product_options item=option}
<li style="border-top: none; padding: 0px; text-transform: uppercase; color: #9e9e9e;">{$option.class}: {$option.option_name}</li>
{/foreach}
<li style="border-top: none; padding: 0px; text-transform: uppercase; color: #9e9e9e;">Quantity: {$product.amount}</li>
</ul>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</li>
__________________
Sizzle Factor @ www.sizzlefactor.com
Simply X-Cart @ www.simplyxcart.com
VitalBGS @ www.vitalbgs.com
For all of your X-Cart solutions!
X-Cart versions 4.4.0 to 5.0
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 01:24 AM.

   

 
X-Cart forums © 2001-2020