Automattic\WooCommerce\Admin\Notes
Note::set_content_data() public WC 1.0
Set note data for potential re-localization.
{} Это метод класса: Note{}
Хуков нет.
Возвращает
Null. Ничего.
Использование
$Note = new Note(); $Note->set_content_data( $content_data );
- $content_data(объект) (обязательный)
- Note data.
Код Note::set_content_data() Note::set content data WC 5.0.0
public function set_content_data( $content_data ) {
$allowed_type = false;
// Make sure $content_data is stdClass Object or an array.
if ( ! ( $content_data instanceof \stdClass ) ) {
$this->error( 'admin_note_invalid_data', __( 'The admin note content_data prop must be an instance of stdClass.', 'woocommerce' ) );
}
$this->set_prop( 'content_data', $content_data );
}