Space between the currency symbol and the price

WordPress Event Management, Calendars & Registration Forums General Question Space between the currency symbol and the price

This topic contains 2 replies, has 2 voices, and was last updated by  Denis Voelke 3 years ago.

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

    Hello,

    How could I add a space between the currency symbol and the price? Everything is glued and it is not very readable

    I have CHF5.00 and I would like to have CHF 5.00

    CHFspace5.00

    For example Woocommerce allows this setting, wouldn’t it be possible to add it in your plugin?

    Sincerely,

    Denis

    Denis Voelke
    #39575

    Hi Denis,

    This isn’t perhaps the niceset solution, but the following code should achieve that (there is no setting beyond currency position):

    add_filter('eventorganiser_format_price', function($formatted_price, $amount, $price) {
        return str_replace("CHF", "CHF ", $formatted_price);
    }, 10, 3);
    
    Stephen Harris
    #39581

    Hi Stephen,

    That works well, thank you very much!

    Denis

    Denis Voelke
Viewing 3 posts - 1 through 3 (of 3 total)
To enable me to focus on Pro customers, only users who have a valid license for the Pro add-on may post new topics or replies in this forum. If you have a valid license, please log-in or register an account using the e-mail address you purchased the license with. If you don't you can purchase one here. Or there's always the WordPress repository forum.