Dmcwebd Posted January 22, 2011 Share Posted January 22, 2011 I need to add on the product page if there are combinations then it has to show Attribute Name, Quantity for each attribute instead of total quantity.then if there is no combinations shows the total quantity.Could anyone help me out? Link to comment Share on other sites More sharing options...
Dmcwebd Posted January 24, 2011 Author Share Posted January 24, 2011 I found this code which i can show the attribute names on the product page: {if isset($groups)}{strip} {foreach from=$combinations key=idCombination item=combination} {if $combination.quantity > 0} {assign var=attributes value=','|explode:$combination.list} {foreach from=$groups key=id_attribute_group item=group} {foreach from=$group.attributes key=id_attribute item=group_attribute} {foreach from=$attributes item=attribute name=attribute quantity=attribute} {if $id_attribute == $attribute|substr:1:-1} {$group_attribute}{if !$smarty.foreach.attribute.last}, {/if} {/if} {/foreach} {/foreach} {/foreach} {/if} {/foreach} {/strip}{/if} Anyone knows how to show the quantity also? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now