Description
The wsf_currency_default filter allows you to set the default currency used by WS Form. Note that if you are using WooCommerce this setting is ignored. This filter is only applicable prior to WS Form first initializing its options. The currency code should be ISO 3166 (alpha-3) format.
Usage
add_filter( 'wsf_currency_default', 'my_hook_function', 10, 1 );
Parameters
$currency
StringThe default currency code in ISO 3166 (alpha-3) format.Default value:USD
Example
// Callback function for the wsf_currency_default filter hook function my_hook_function( $currency ) { // Your code here ... // Return value return $currency; } // Add a callback function for the wsf_currency_default filter hook add_filter( 'wsf_currency_default', 'my_hook_function', 10, 1 );
Source File
This hook can be found in:<plugin root>/includes/class-ws-form-common.php