[Skip to main content](#vessel-content)

#   how to change the display for discounts

##

- **[bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")**
- [![bonaventure's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/3439-bonaventure "View bonaventure's Profile") Topic Author
- [ Offline](/forum/user/3439-bonaventure)

Less More

- Posts: 2
- Thank you received: 0
-
-

15 years 4 months ago [\#21930](#21930) by [bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")  *[how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#21930 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")* was created by *[bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")*

First of all, wow, what a fantastic component.

Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.

For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as "$20 -20% each". This reads as if the customer will get an additional 20%.

I changed the language file so that its says "$20 -20% savings" but this is awkward, particularly with the hyphen (which many will translate as a "subtract" sign).

The price listing is a bit misleading because the product is originally $25, so it should say:
$20 (Save 20%) or $20 (originally $25) or something without the hyphen.

Any thoughts?

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86586
- Thank you received: 14325
-
-

15 years 4 months ago [\#21934](#21934) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#21934 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

Hi,

Near the top of the translation file, you will find the text:

PRICE_DISCOUNT_START=""
PRICE_DISCOUNT_END=""

By overriding these translations you can add your parentheses to the discounts information of prices:
[ www.hikashop.com/download/languages.html#modify](http://www.hikashop.com/download/languages.html#modify)

You can also change the way the discount is displayed (a percentage or the original amount) with the option "Show discounted price" in the Display tab of the config and with the same option in the hikashop options each of your menus/modules that you can access via the menu Display-&gt;Content menus/modules

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")**
- [![bonaventure's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/3439-bonaventure "View bonaventure's Profile") Topic Author
- [ Offline](/forum/user/3439-bonaventure)

Less More

- Posts: 2
- Thank you received: 0
-
-

15 years 4 months ago [\#21939](#21939) by [bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")  Replied by *[bonaventure](/forum/user/3439-bonaventure "View bonaventure's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#21939 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

Thank you for your prompt and very helpful response.

I created the following overrides.
PRICE_DISCOUNT_START="(save"
PRICE_DISCOUNT_END=")"

But I can't get rid of the hyphen. It should say (save 20%) but it says (save-20%). It's a small thing that I can live with but I would change it if it could be done. I also tried your suggestion to "display the price before the discount is applied". It worked in the shopping cart module but it didn't impact the product display in the main body. I keep digging in the help files and configuration as I'm certain that I'm missing something simple.

Thanks again for a great product and great support.  [ ![&#91;img](http://www.hikashop.com/media/kunena/attachments/legacy/images/hyphen.jpg) ](http://www.hikashop.com/media/kunena/attachments/legacy/images/hyphen.jpg "&#91;img")

- [ ![hyphen.jpg](/forum/attachment/1497) ](/forum/attachment/1497 "hyphen.jpg") [ ](/forum/attachment/1497?download=1 "hyphen.jpg")

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86586
- Thank you received: 14325
-
-

15 years 4 months ago [\#21941](#21941) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#21941 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

If you want to remove the - symbol, you can edit the file listing_price of the view product via the menu Display-&gt;Views and change the line:
echo -1*$this-&gt;row-&gt;discount-&gt;discount_percent_amount.'%';

to:
echo $this-&gt;row-&gt;discount-&gt;discount_percent_amount.'%';

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[vilost](/forum/user/342-vilost "View vilost's Profile")**
- [![vilost's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/342-vilost "View vilost's Profile")
- [ Offline](/forum/user/342-vilost)

Less More

- Posts: 19
- Thank you received: 0
-
-

14 years 10 months ago -  14 years 10 months ago [\#33897](#33897) by [vilost](/forum/user/342-vilost "View vilost's Profile")  Replied by *[vilost](/forum/user/342-vilost "View vilost's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#33897 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

I have followed this thread but it doesn't seem to solve the problem. The suggested modifications produce this
**430,00 € (you save -240,00 €) each**.
The minus sign is still there when the discounted amount is not a percentage. Getting rid of the minus sign is not a problem but in the single product view you get this
**430,00 € (\[strike\]you save 670,00\[/strike\] €) each**.
You see that the what is in the bracket is not the discounted amount but the price before the discount.

To avoid any confusions I would be glad if you could guide me to achieve something like the attached image  [ ![&#91;img](http://www.hikashop.com/media/kunena/attachments/legacy/images/image3-20111228.jpg) ](http://www.hikashop.com/media/kunena/attachments/legacy/images/image3-20111228.jpg "&#91;img")

- [ ![image3-20111228.jpg](/forum/attachment/2307) ](/forum/attachment/2307 "...3-20111228.jpg") [ ](/forum/attachment/2307?download=1 "...3-20111228.jpg")

Last edit: 14 years 10 months ago by [vilost](/forum/user/342-vilost "View vilost's Profile").

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[nicolas](/forum/user/63-nicolas "View nicolas's Profile")**
- [![nicolas's Avatar](https://www.hikashop.com/media/kunena/avatars/resized/size144/users/avatar63.png?1793428657)](/forum/user/63-nicolas "View nicolas's Profile")
- [ Offline](/forum/user/63-nicolas)

Less More

- Posts: 86586
- Thank you received: 14325
-
-

14 years 10 months ago [\#33909](#33909) by [nicolas](/forum/user/63-nicolas "View nicolas's Profile")  Replied by *[nicolas](/forum/user/63-nicolas "View nicolas's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#33909 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

The options won't be enough to display all three prices at the same time.
For that, you'll have to edit the file "listing_price" of the view "product" via the menu Display-&gt;Views.

You could use something like that for example:

echo $this-&gt;currencyHelper-&gt;format($price-&gt;price_orig_value_without_discount,$price-&gt;price_orig_currency_id). ' ' .$this-&gt;currencyHelper-&gt;format($price-&gt;price_orig_value,$price-&gt;price_orig_currency_id). '&lt;br/&gt;You save: ' .$this-&gt;currencyHelper-&gt;format($price-&gt;price_orig_value_without_discount-$price-&gt;price_orig_value,$price-&gt;price_orig_currency_id);

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

- **[vilost](/forum/user/342-vilost "View vilost's Profile")**
- [![vilost's Avatar](https://www.hikashop.com/media/kunena/core/svg/person.svg)](/forum/user/342-vilost "View vilost's Profile")
- [ Offline](/forum/user/342-vilost)

Less More

- Posts: 19
- Thank you received: 0
-
-

14 years 10 months ago [\#34099](#34099) by [vilost](/forum/user/342-vilost "View vilost's Profile")  Replied by *[vilost](/forum/user/342-vilost "View vilost's Profile")* on topic *[Re: how to change the display for discounts](/forum/4-how-to/21930-how-to-change-the-display-for-discounts#34099 "First of all, wow, what a fantastic component.  Second, I created a discount for my products but I don't like the wording of the discount per product. I found the appropriate language file but I would like to get rid of the hyphen (or minus sign), which does not appear to be in the language file. I prefer to hack the core to avoid problems when upgrading.  For example, one my products sells for $25 with a 20% discount. It appears on the website to customers as &quot;$20 -20% each&quot;. This reads as if the customer will get an additional 20%.  I changed the language file so that its says &quot;$20 -20% savings&quot; but this is awkward, particularly with the hyphen (which many will translate as a &quot;subtract&quot; sign).  The price listing is a bit misleading because the product is originally $25, so it should say: $20 (Save 20%) or $20 (originally $25) or something without the hyphen.  Any thoughts?")*

No luck. I tried but did not succeed. I dont know php enough so I dont know which lines to replace in the code or where exactly to place the code. After trying different options in the default Hikashop setting I was able to get something like this
**430 € (\[strike\]670 €\[/strike\]) each**
I am OK with that for the moment.

Please [Log in](/login?return=aHR0cHM6Ly93d3cuaGlrYXNob3AuY29tL2ZvcnVtLzQtaG93LXRvLzIxOTMwLWhvdy10by1jaGFuZ2UtdGhlLWRpc3BsYXktZm9yLWRpc2NvdW50cz90bXBsPW1hcmtkb3du) or [Create an account](/component/users/registration?Itemid=101) to join the conversation.

Board Categories HikaShop Install &amp; Update Product &amp; Category Display Content Creation Sales and Orders Orders management Reports &amp; Statistics Customers Checkout Payment Methods Shipping Methods Import &amp; Export (CSV, XLS…) Specific Features Affilation Taxes Wishlist Vote Carousel &amp; Slider Mass Actions Filters &amp; Search Discount &amp; Coupon Feature Request Integrations Showcase General Talk about HikaShop Development HikaShop 3.0 Beta Translation Commercial Jobs HikaShop Components HikaMarket Market: Feature requests Market: How to? Market: Bug Report HikaSerial General talk about HikaSerial Serial: Bug Report Serial: How to? Support en Français de HikaSerial (French Support) HikaSubscription HikaAuction Auction: Feature requests Auction: How to? Auction: Bug report Hikashop around the world Support en Français (French Support) Russian FAQ. Курс выживания с Hikashop. Частые вопросы и о Расширения Hikashop Наши сайты на Hikashop 日本語版サポート(Japanese Support) Thai German Archives Bug Report How to?

[](/forum/topics/feed/mode-topics?format=feed&type=rss)

Time to create page: 0.075 seconds

[Powered by](/forum/credits) [Kunena Forum](https://www.kunena.org)
