- Posts: 65
- Thank you received: 0
Show price filter without decimals
galeriadeartepedropena.com/tienda
I want it to show 500 instead of 500,00 (to many 0´s makes it confusing)
Do you know how to do this?
Please Log in or Create an account to join the conversation.
There is no option for that.
If you want to do that you will have to change the lines:
$formatVal=$currencyClass->format($formatVal,$currency);
if($key!=0){ $oldVal=$currencyClass->format($oldVal,$currency); }
by:
$formatVal=str_replace(',00','',$currencyClass->format($formatVal,$currency));
if($key!=0){ $oldVal=str_replace(',00','',$currencyClass->format($oldVal,$currency)); }
in the file administrator/components/com_hikashop/classes/filter.php
However, that is a core file of HikaShop so you will loose that modification when you update HikaShop.
Please Log in or Create an account to join the conversation.
I just want the price shown without decimals, currency and the phrase "per unit".
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
You can actually even if it's less nice.
edit the file "filter" of the view "product" via the menu Display->Views and change the line:
$html[$key]=$this->filterClass->displayFilter($filter, $this->params->get('main_div_name'), $this, $datas);
by:
$html[$key]=str_replace(',00',' per unit',$this->filterClass->displayFilter($filter, $this->params->get('main_div_name'), $this, $datas));
Please Log in or Create an account to join the conversation.
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
I removed the edited file and redid the mod but it doesn't change.
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
It can sometimes mess the saving of the modifications.
Please Log in or Create an account to join the conversation.
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
Maybe joomla don't have write access to the folder where that override file needs to be written to ?
In that case, you should change the permissions of the folder templates/YOUR_TEMPLATE/html/com_hikashop/product to allow that.
Please Log in or Create an account to join the conversation.
As it is at the moment the site is on my Mac under localhost. I will upload everything in a few days to my InternetHost, then you can take a look your self.
I can live with it for the moment, it is just cosmetic.
What's more important is this issue: www.hikashop.com/en/forum/4-how-to/41662...ing-in-listview.html
Jan
Jan Suhr
www.colorconsult.se www.jansuhr.se
Please Log in or Create an account to join the conversation.
Please Log in or Create an account to join the conversation.
Can you advise me on this
Thanks
Please Log in or Create an account to join the conversation.
For the price of products, you just need to edit your currency via the menu System->Currencies and change the decimal option of your currency to what you want.
Please Log in or Create an account to join the conversation.