WP_Translation_Controller::set_locale
Sets the current locale.
Method of the class: WP_Translation_Controller{}
No Hooks.
Returns
null. Nothing (null).
Usage
$WP_Translation_Controller = new WP_Translation_Controller(); $WP_Translation_Controller->set_locale( $locale );
- $locale(string) (required)
- Locale.
Changelog
| Since 6.5.0 | Introduced. |
WP_Translation_Controller::set_locale() WP Translation Controller::set locale code WP 6.9.1
public function set_locale( string $locale ) {
$this->current_locale = $locale;
}