restore_previous_locale action-hook . WP 4.7.0
Fires when the locale is restored to the previous one.
Usage
add_action( 'restore_previous_locale', 'action_function_name_5389', 10, 2 ); function action_function_name_5389( $locale, $previous_locale ){ // action... }
- $locale(string)
- The new locale.
- $previous_locale(string)
- The previous locale.
Changelog
Since 4.7.0 | Introduced. |
Where the hook is called
restore_previous_locale
wp-includes/class-wp-locale-switcher.php 129
do_action( 'restore_previous_locale', $locale, $previous_locale );