Jump to content

[SOLVED] Prestashop - Show the prices are tax excluded for visitors


Captain Harlock

Recommended Posts

0 down vote favorite

 

Greetings !

 

I am on Prestashop 1.6.

 

When a user is a guest or a member, the mention "tax excl." is displayed next to the price in the products sheets.

Like this :

tcAgH.jpg

I would like this text to appear also for the visitors.

 

For visitors, it currently shoows like this :

HhUVr.jpg

 

Thank you in advance for your help ! :)

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

Well, in /theme/default-bootstrip/product.tpl, about the line 260, I got the following code :

<p class="our_price_display" itemprop="offers" itemscope itemtype="https://schema.org/Offer">{strip}
                                    {if $product->quantity > 0}<link itemprop="availability" href="https://schema.org/InStock"/>{/if}
                                    {if $priceDisplay >= 0 && $priceDisplay <= 2}
                                        <span id="our_price_display" class="price" itemprop="price" content="{$productPrice}">{convertPrice price=$productPrice|floatval}</span>
                                        {if $tax_enabled  && ((isset($display_tax_label) && $display_tax_label == 1) || !isset($display_tax_label))}
                                            {if $priceDisplay == 1} {l s='tax excl.'}{else} {l s='tax incl.'}{/if}
                                        {/if}
                                        <meta itemprop="priceCurrency" content="{$currency->iso_code}" />
                                        {hook h="displayProductPriceBlock" product=$product type="price"}
                                    {/if}
                                {/strip}</p>

I am pretty sure that's the default code, but if anyone has something else and the label "tax excl" appears even for guest, tell me :)

Link to comment
Share on other sites

I think I found the solution. In product.tpl, replace

<span id="our_price_display" class="price" itemprop="price" content="{$productPrice}">{convertPrice price=$productPrice|floatval}</span>
                                       {if $tax_enabled  && ((isset($display_tax_label) && $display_tax_label == 1) || !isset($display_tax_label))}
                                            {if $priceDisplay == 1} {l s='tax excl.'}{else} {l s='tax incl.'}{/if}
                                        { /if}

With :

<span id="our_price_display" class="price" itemprop="price" content="{$productPrice}">{convertPrice price=$productPrice|floatval}</span>
                                            {if $priceDisplay == 1} {l s='tax excl.'}{else} {l s='tax incl.'}{/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...