Currency Symbol Change

Viewing 9 posts - 1 through 9 (of 9 total)
  • Author
    Posts
  • #697550
    Manoj
    Participant

    Hi
    We have selected United Arab Emirates Dirham as the currency and we get currency symbol in Arabic letters. Instead of that we just need AED as a symbol and we tried below code from another topic to create a new currency.

    add_filter( ‘mprm_currencies’, ‘add_my_currency’ );

    function add_my_currency( $currencies ) {
    $currencies[‘TEST’] = __( ‘Currency name’, ‘mprm’ );
    return $currencies;
    }

    but nothing happened. Please guide us to change it to AED in place of Arabic letters.

    Thanks and Regards

    Manoj KB

    #698060
    J. Davis
    Keymaster

    Hi Manoj,
    We are going to update currency list in a new version. Stay tuned to to miss this release.
    Meanwhile you can use the code below to edit currency label of United Arab Emirates Dirham

    add_filter('mphb_currency_symbols', 'change_aed_currency_symbol',  10, 2);
    
    function change_aed_currency_symbol ( $currency_symbol ) {
        $currency_symbol['AED'] = ('AED');
        return $currency_symbol;
    }
    #698106
    Manoj
    Participant

    Hi J. Davis

    It worked perfectly for us. Great support and waiting for the new version.

    Thanks and Regards

    Manoj

    #754968
    Stacy Lind
    Keymaster

    All the missing currencies were added in version 2.7.5 of MotoPress Hotel Booking.

    #1507901
    Patricia Llonch
    Participant

    Hi! I would like to use “USD” or “u$s” or any similar symbol to indicate our prices are set in american dollars, instead of plain “$”, which can be taken as argentinian pesos.
    Thank you in advance!

    #1510068
    J. Davis
    Keymaster

    Hi Patricia,
    Yes here is an example for USD:

    add_filter('mphb_currency_symbols', 'change_usd_currency_symbol');
    
    function change_usd_currency_symbol ( $currency_symbol ) {
        $currency_symbol['USD'] = ('USD');
        return $currency_symbol;
    }
    #1510108
    Patricia Llonch
    Participant

    Thank you very much, J!

    #1512794
    Patricia Llonch
    Participant
    This reply has been marked as private.
    #1518062
    J. Davis
    Keymaster

    Hi Patricia,

    Please make sure you added the code to the end of the functions.php file. I tested the code and it worked correctly

Viewing 9 posts - 1 through 9 (of 9 total)
  • You must be logged in to reply to this topic.