0
add_filter( 'gform_field_value_bank20_code', 'my_custom_population_showcountry' );
function my_custom_population_showcountry( $value ) {
$current_user = wp_get_current_user();
$users = $current_user->PROCESSOR;

 // For the country Afghanistan
 if( $current_user->PROCESSOR == 'Afghanistan' )
$users = ( '500' );

// For the country Albania
if( $current_user->PROCESSOR == 'Albania' )
$users = ( '600' );

// For the country Algeria
if( $current_user->PROCESSOR == 'Algeria' )
$users = ( '600' );

// For the country American Samoa
if( $current_user->PROCESSOR == 'American Samoa' )
$users = ( '600' );


return $users;    
}

现在,由于我们使用上面的代码,我希望我们在该数字列中添加一个 google api 货币汇率或 yahoo 金融汇率,以便汇率将自动更新,而不是使用手动方法更新。这将适用于每个国家。

4

0 回答 0