Jump to content

Product quantity: show more than xx in stock


Recommended Posts

Hi there.

 

I would need a little help with product quantity display.

 

Can someone tell me how should it be done if I want to show for example “ More than 10pcs in stock “ as long as there is more than 10. When stock goes 10 or less, quantity should be displayed as numbers, 10,9,8.. and so on pcs in stock.

 

Maybe there is already solution for this? 

Link to comment
Share on other sites

I used this on a site, product.tpl

							{if $product->quantity > 10}
								{l s='10+'} {l s='in Stock'}
							{else if $product->quantity > 5}
								{l s='5+'} {l s='in Stock'}
							{else} 
								{l s='Few'} {l s='in Stock'}!
							{/if}

Link to comment
Share on other sites

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...