Tagged: 

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #8051

    I want to change or to add a new currency price, for example to change $ with lv. How should I do this ?

    #60143

    you can see how to add any currency you want here: http://pastie.org/2905821

    i ‘ve just added romanian leu (ron)

    #60144

    I think there’s a better solution. Add following code to functions.php:

    add_filter( 'woocommerce_currencies', 'add_custom_currency' );

    function add_custom_currency( $currencies ) {
    $currencies['3DIGITCODE'] = __( 'Name of Currency', 'woothemes' );
    return $currencies;
    }

    add_filter( 'add_currency_symbol', 'add_custom_symbol');

    function add_custom_symbol() {
    $currency = get_option( 'woocommerce_currency' );
    switch( $currency ) {
    case '3DIGITCODE': $symbol = '€'; break;
    }
    return $symbol;
    }

    Replace 3DIGITCODE, the symbol (€) and the name of the currency with your currency details.

Viewing 3 posts - 1 through 3 (of 3 total)

The topic ‘Change of the Woocommerce price currency’ is closed to new replies.