X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Changing design (https://forum.x-cart.com/forumdisplay.php?f=51)
-   -   Hide numbers after the decimal point in price (https://forum.x-cart.com/showthread.php?t=63058)

pdstudio 03-23-2012 03:52 AM

Hide numbers after the decimal point in price
 
Hy,
I have a solution for the hiding of the numbers after the decimal point in the product price, for those, who dont want to use it.
You must apply the following SQL-query:
Code:

UPDATE xcart_config SET variants="2.,:1,999.53\n2.:1999.53\n2, :1 999,53\n2,.:1.999,53\n0  :1 999" WHERE name="number_format";

It will add new selection entry to the "General Settings" -> "Appearance" options page for the number format option.

You can also add the "0 :1 999" manually to a new line when you search after the xcart_config entry for example in phpMyAdmin.

Note that it is recommended to back up the database before making any changes!

I use X-Cart 4.4.4 and I did not test other versions

mirage00 03-04-2013 08:49 AM

Re: Hide numbers after the decimal point in price
 
This change works for the display but you will have rounding errors... What I have discovered is XCART needs to seperate the display format from the precision format. I need to have prices entered into the system with 4 digit precision $ .1034 as an example. This is needed when someone purchases large quantities 5000+ of the same item. But the final price for the purchase should be display in $xxx.xx format.


All times are GMT -8. The time now is 05:41 PM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.