WP_Locale_Switcher::init()

Initializes the locale switcher.


Description

Hooks into the ‘locale’ and ‘determine_locale’ filters to change the locale on the fly.


Top ↑

Source

File: wp-includes/class-wp-locale-switcher.php. View all references

public function init() {
	add_filter( 'locale', array( $this, 'filter_locale' ) );
	add_filter( 'determine_locale', array( $this, 'filter_locale' ) );
}


Top ↑

Changelog

Changelog
Version Description
4.7.0 Introduced.

Top ↑

User Contributed Notes

You must log in before being able to contribute a note or feedback.