Skip to content

Instantly share code, notes, and snippets.

@pramodjodhani
Created July 23, 2025 17:20
Show Gist options
  • Save pramodjodhani/e3867b74d2a92885cfb95a20856970db to your computer and use it in GitHub Desktop.
Save pramodjodhani/e3867b74d2a92885cfb95a20856970db to your computer and use it in GitHub Desktop.
Add UAE Dirham (AED) currency to Gravity Forms.
<?php
/**
* Add UAE Dirham (AED) currency to Gravity Forms.
*
* @param array $currencies The current currencies registered in Gravity Forms.
* @return array List of supported currencies with AED added.
*/
function add_aed_currency_to_gf( $currencies ) {
$currencies['AED'] = array(
'name' => 'United Arab Emirates Dirham',
'symbol_left' => 'د.إ',
'symbol_right' => '',
'symbol_padding' => ' ',
'thousand_separator' => ',',
'decimal_separator' => '.',
'decimals' => 2,
'code' => 'AED',
);
return $currencies;
}
add_filter( 'gform_currencies', 'add_aed_currency_to_gf' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment