Automattic\WooCommerce\Admin\Notes
Note::set_locale()
Set note locale.
Method of the class: Note{}
No Hooks.
Return
null
. Nothing (null).
Usage
$Note = new Note(); $Note->set_locale( $locale );
- $locale(string) (required)
- Note locale.
Note::set_locale() Note::set locale code WC 9.7.1
public function set_locale( $locale ) { if ( empty( $locale ) ) { $this->error( 'admin_note_invalid_data', __( 'The admin note locale prop cannot be empty.', 'woocommerce' ) ); } $this->set_prop( 'locale', $locale ); }