View Single Post
  #3  
Old 03-22-2008, 02:51 AM
 
donavichi donavichi is offline
 

X-Adept
  
Join Date: Apr 2004
Location: United Kingdom
Posts: 697
 

Default Re: EZUPSELL 3 column display

Here's a 4.0 version of ezUpsell with a 4-column display. If you want to change the number of columns, change the '{ if %cat_num.index% is div by 4 }' to the number of columns that you require.

You get a thumbnail above the product title for each item.

Code:
{capture name=upsell} <table border="0" align="center" cellpadding="2" cellspacing="0"> <tr> <td valign="top"><div align="center">{include file="product_thumbnail.tpl" productid=$product_info.productid image_x=$config.Appearance.thumbnail_width product=$product_info.product tmbn_url=$product_info.tmbn_url}&nbsp;</div></td></tr> <tr> <td valign="top"> <div align="center"><font size="3" face="Arial"><b>{$lng.lbl_you_have_added} {$amount} &quot;{$product_info.product}{if $amount > 1}s{/if}&quot; {$lng.lbl_to_your_shopping_cart}.</b></font> <br /> <font class="Text">What would you like to do now?</font></div></td> </tr> </table> <div align="center"> <table border="0" cellspacing="0" cellpadding="0" width="411" height="43"> <tr> <td width="195" height="43" background="{$ImagesDir}/ez_continueshopping.gif"> <p align="center"><a href="home.php?cat={$product_info.categoryid}&page={$page}"><font color="#FFFFFF" size=2><b>{$lng.lbl_continue|upper}</b></font></a></td> <td width="216" height="43" background="{$ImagesDir}/ez_checkout.gif"> <p align="center"><a href="cart.php"><font color="#FFFFFF" size=2><b>{$lng.lbl_checkout|upper}</b></font></a></td> </tr> </table> </div> <hr noshade size=1> {if $product_links ne ""} <p><font face="Arial" size="2"><b>These products go really well with {$product_info.product}:</b></font></p> {section name=cat_num loop=$product_links} { if %cat_num.first% } <table border=0 width="100%">{/if} { if %cat_num.index% is div by 4 }<tr>{/if} <td style="padding-left:4px;padding-right:4px;padding-top:5px;padding-bottom:5px;" width="25%" align="center" valign="top"><a href="product.php?productid={ $product_links[cat_num].productid }">{include file="product_thumbnail.tpl" productid=$product_links[cat_num].productid product=$product_links[cat_num].product tmbn_url=$product_links[cat_num].tmbn_url}</a><br /> <a href="product.php?productid={ $product_links[cat_num].productid }">{ $product_links[cat_num].product|escape}</a></td> { if %cat_num.last% }</tr> </table>{/if} {/section} {/if} <br> {/capture} {include file="dialog.tpl" title=$lng.lbl_productadded content=$smarty.capture.upsell extra="width=100%"}
__________________
Best regards,

Donavichi.
- - -

Website Copywriting || Web Design || FAQs || Home & Garden Blog
Reply With Quote