removing the fraction from price filter

hi all i want to remove the fraction numbers from the price filter to avoid second line as u can see in the attached image how can i do it



it is always in my site without fraction so there is no need to show it just in this filter



price-filter.jpg

hope any help for that

[quote name=‘majed’]hi all i want to remove the fraction numbers from the price filter to avoid second line as u can see in the attached image how can i do it



it is always in my site without fraction so there is no need to show it just in this filter



[/QUOTE]



In the “Catalog” > “Product filters” section, look at the price filter.



In the “Name” box, you might see something like this: “%100:price% - %150:price%”

This automatically formats the price correctly for whatever currency you’re using. You can manually edit that field to say $100 - $150 or 100GBP - 150GDP or whatever.



That’s the easy way to do it without having to hack any templates.



If you want to do away with decimals altogether, you can edit the “currencies” table and set the “decimals” column to “0”.

hi thx a lot for u i need to set it

“%100price% - %150price%”



so that i have the two version of the website work



( arabic Kuwait dinar KD - english Dollar $ )



can i just make the edit on the price filter so that it work dynamic with currency change ??





thx again for ur help

You need the edit the table in the “currencies” table in the database so the Kuwaiti Dinar. Edit the field “decimals” for the Kuwaiti Dinar and change it from 2 to 0.

thx a lot for u it is work fine but it will apply for all the site and i want it just in the price filter if it is dowable

The filter block template is generic. It doesn’t know what it is filtering by.



What you’d need to do is a replace like this (about line 57):



{$filter.prefix}{$range.range_name|fn_text_placeholders}{$filter.suffix} ({$range.products})




with this:


{$filter.prefix}{$range.range_name|fn_text_placeholders|replace:".00":""}{$filter.suffix} ({$range.products})




That should work.

thx a lot for ur help



you said i need to do is a replace like this (about line 57):



which file you mean can i have the path plz



thx again

I apologise, the file is:



/skins/{YOUR_SKIN}/customer/products/blocks/product_filters.tpl