SHARE
TWEET

Untitled

a guest Jun 18th, 2019 60 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. add_filter('wc_price_args', 'wc_force_decimals_for_price_display');
  2. function wc_force_decimals_for_price_display($args) {
  3.     if (isset($args['force_decimals'])) {
  4.         $args['decimals'] = $args['force_decimals'];
  5.     } else {
  6.         $args['decimals'] = 2;
  7.     }
  8.  
  9.     return $args;
  10. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top