Jump to content

template viable for product addons


steve_ec

Recommended Posts

I'm trying to figure out how to add a list of addons related to each product while browsing the products/services.

 

In the template file configureproduct.tpl the $addons and $addon variables are available.

I'm having trouble finding the means of adding these for the products.tpl file.

 

Any help would be appreciated.

 

Thanks!

 

Steve

Link to comment
Share on other sites

This is taken directly from the configureproduct.tpl template:

 

{if $addons}
<tr><td colspan="2"><strong>{$LANG.cartaddons}</strong></td></tr>
<tr class="orderheadingrow"><td colspan="2"></td></tr>
{foreach key=num item=addon from=$addons}
<tr class="orderrow{if $num % 2}2{else}1{/if}"><td>{$addon.checkbox}</td><td><label for="a{$addon.id}"><strong>{$addon.name}</strong> - {$addon.description} ({$addon.pricing})</label></td></tr>
{/foreach}
<tr class="orderheadingrow"><td colspan="2"></td></tr>
<tr><td height="10"></td></tr>
{/if}

 

Here is some code that is dumbed down so its easier to understand:

 

{if $addons}
{foreach key=num item=addon from=$addons}
{$addon.checkbox} {$addon.name} - {$addon.description}  ({$addon.pricing})<br />
{/foreach}
{/if}

 

This should create a list of checkboxes for each addon available.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated