mfermo Posted July 2, 2013 Share Posted July 2, 2013 Hello, I was wondering if there's a way in case a product is not available (stock = 0) not to display the price and in that field have a message (for example 'Sold'). Thx for your help! Link to comment Share on other sites More sharing options...
NemoPS Posted July 3, 2013 Share Posted July 3, 2013 Hi, You must edit product.tpl for this (theme folder) FInd this <p class="our_price_display"> {if $priceDisplay >= 0 && $priceDisplay <= 2} <span id="our_price_display">{convertPrice price=$productPrice}</span> <!--{if $tax_enabled && ((isset($display_tax_label) && $display_tax_label == 1) OR !isset($display_tax_label))} {if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if} {/if}--> {/if} </p> Specifically, this part <span id="our_price_display">{convertPrice price=$productPrice}</span> Change it to <span id="our_price_display"> {if $product->quantity <= 0} {l s='Sold out!'} {else} {convertPrice price=$productPrice} {/if} </span> Of course this WILL NOT work with combinations. 2 Link to comment Share on other sites More sharing options...
mfermo Posted July 5, 2013 Author Share Posted July 5, 2013 Hi, You must edit product.tpl for this (theme folder) FInd this <p class="our_price_display"> {if $priceDisplay >= 0 && $priceDisplay <= 2} <span id="our_price_display">{convertPrice price=$productPrice}</span> <!--{if $tax_enabled && ((isset($display_tax_label) && $display_tax_label == 1) OR !isset($display_tax_label))} {if $priceDisplay == 1}{l s='tax excl.'}{else}{l s='tax incl.'}{/if} {/if}--> {/if} </p> Specifically, this part <span id="our_price_display">{convertPrice price=$productPrice}</span> Change it to <span id="our_price_display"> {if $product->quantity <= 0} {l s='Sold out!'} {else} {convertPrice price=$productPrice} {/if} </span> Of course this WILL NOT work with combinations. Hi I just tried and works nice! Thank you. The only "weakness" is that it takes out price only when I am viewing the product. Is there a way of taking out the price (under the condition products is not avaiable) on all views (like when is listed under a category, or under the manufacturer, ecc). thx for your help! 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