Jump to content

Display all currencies under product


chaiwat

Recommended Posts

Hi,

 

I'm not good in English. I try to display all product prices in all currencies.

 

 

<p class="price_container">
<span class="price">{if !$priceDisplay}{convertPriceWithCurrency price=$product.price currency=$currencies.0 convert=true}{else}{ }{/if}</span><br />
<span class="price">{if !$priceDisplay}{convertPriceWithCurrency price=$product.price currency=$currencies.1 convert=true}{else}{convertPrice price=$product.price_tax_exc}{/if}</span><br />
<span class="price">{if !$priceDisplay}{convertPriceWithCurrency price=$product.price currency=$currencies.2 convert=true}{else}{convertPrice price=$product.price_tax_exc}{/if}</span><br />
<span class="price">{if !$priceDisplay}{convertPriceWithCurrency price=$product.price currency=$currencies.3 convert=true}{else}{convertPrice price=$product.price_tax_exc}{/if}</span><br />
<span class="price">{if !$priceDisplay}{convertPriceWithCurrency price=$product.price currency=$currencies.4 convert=true}{else}{convertPrice price=$product.price_tax_exc}{/if}</span><br />
</p>

 

post-134259-0-00408400-1355911522_thumb.png

 

I don't know much about programming, please help.

 

Prestashop 1.4.5.1

Edited by chaiwat (see edit history)
Link to comment
Share on other sites

{if !$priceDisplay}
						 {if $currency->id == 4}
						  {convertPriceWithCurrency price={$product.price*$currencies.0.conversion_rate} currency=$currencies.0 convert=true}
							 <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.1.conversion_rate} currency=$currencies.1 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.2.conversion_rate} currency=$currencies.2 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.3.conversion_rate} currency=$currencies.3 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.4.conversion_rate} currency=$currencies.4 convert=true}								   
						    {elseif $currency->id == 2}
							 {convertPriceWithCurrency price={$product.price/$currencies.1.conversion_rate} currency=$currencies.0 convert=true}
							 <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.1.conversion_rate/$currencies.1.conversion_rate} currency=$currencies.1 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.2.conversion_rate/$currencies.1.conversion_rate} currency=$currencies.2 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.3.conversion_rate/$currencies.1.conversion_rate} currency=$currencies.3 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.4.conversion_rate/$currencies.1.conversion_rate} currency=$currencies.4 convert=true}
						    {elseif $currency->id == 1}
							 {convertPriceWithCurrency price={$product.price/$currencies.2.conversion_rate} currency=$currencies.0 convert=true}
							 <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.1.conversion_rate/$currencies.2.conversion_rate} currency=$currencies.1 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.2.conversion_rate/$currencies.2.conversion_rate} currency=$currencies.2 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.3.conversion_rate/$currencies.2.conversion_rate} currency=$currencies.3 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.4.conversion_rate/$currencies.2.conversion_rate} currency=$currencies.4 convert=true}
						    {elseif $currency->id == 5}
							 {convertPriceWithCurrency price={$product.price/$currencies.3.conversion_rate} currency=$currencies.0 convert=true}
							 <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.1.conversion_rate/$currencies.3.conversion_rate} currency=$currencies.1 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.2.conversion_rate/$currencies.3.conversion_rate} currency=$currencies.2 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.3.conversion_rate/$currencies.3.conversion_rate} currency=$currencies.3 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.4.conversion_rate/$currencies.3.conversion_rate} currency=$currencies.4 convert=true}
						    {elseif $currency->id == 6}
							 {convertPriceWithCurrency price={$product.price/$currencies.4.conversion_rate} currency=$currencies.0 convert=true}
							 <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.1.conversion_rate/$currencies.4.conversion_rate} currency=$currencies.1 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.2.conversion_rate/$currencies.4.conversion_rate} currency=$currencies.2 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.3.conversion_rate/$currencies.4.conversion_rate} currency=$currencies.3 convert=true}
							    <br />
							 {convertPriceWithCurrency price={$product.price*$currencies.4.conversion_rate/$currencies.4.conversion_rate} currency=$currencies.4 convert=true}
						    {/if}
					    {/if}

 

Finally I try my best, see the picture.

 

post-134259-0-86321900-1356105847_thumb.png

Link to comment
Share on other sites

  • 4 years later...

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...