- This topic has 4 replies, 3 voices, and was last updated 9 years, 2 months ago by .
Viewing 5 posts - 1 through 5 (of 5 total)
Viewing 5 posts - 1 through 5 (of 5 total)
- You must be logged in to reply to this topic.
Support site for Tips and Tricks HQ premium products
by
Tips and Tricks HQ Support Portal › Forums › Simple PayPal Shopping Cart › Simple Shopping Cart Tweaks › Tweaking how the amount is displayed.
Tagged: Japanese decimal, Simple Shopping Cart
If you want to tweak how the total amount is displayed in the simple shopping cart then open the “wp_shopping_cart.php” file and look for the following function:
function print_payment_currency($price, $symbol, $decimal)
{
return $symbol.number_format($price, 2, $decimal, ',');
}
This is the function that displayed the amount to two decimal places. Tweak it to however you want to display your price amount.
Hi.
It seems like this would be a candidate for a variable in the settings page with the currency, e.g.:
Currency Code JPY
Currency Symbol ¥
Decimal Places 0
Having to edit the PHP file every time the software gets updated will get old (and be prone to error).
In any case, would you please be so kind as to let me know where this resides in the full paid version? I’ve tried editing wp_eStore1.php with:
$num_of_decimals = 0; //$wp_eStore_config->getValue('eStore_price_num_decimals');
if (!is_numeric($num_of_decimals)) {
$num_of_decimals = "0";
As well as editing eStore_configs.php:
$wp_eStore_config->addValue('eStore_price_num_decimals', 0);
That doesn’t seem to have done the trick for me.
Cheers!
Solved it, I think.
In wp_eStore1.php, I changed line 1041 of function format_eStore_price_amount:
$num_of_decimals = 0; //intval($num_of_decimals);
I hope that helps somebody.
Cheers.
You can choose your price display formatting settings from the advanced settings of the eStore plugin. Not need to modify any code.
Go to the following settings area:
WP eStore Settings -> Advanced Settings -> Price Display Settings
You know, I JUST found that about 30 seconds ago. May I please have a napkin to wipe the egg off my face? *giggle*
Thank you for your patience.