WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru Платформа для конвертации и монетизации трафика
функция не описана

Automattic\WooCommerce\Admin\Notes

WC_Admin_Notes_WooCommerce_Subscriptions::get_note() public WC 1.0

Get the note.

{} Это метод класса: WC_Admin_Notes_WooCommerce_Subscriptions{}

Хуков нет.

Возвращает

Null. Ничего.

Использование

$result = WC_Admin_Notes_WooCommerce_Subscriptions::get_note();

Код WC_Admin_Notes_WooCommerce_Subscriptions::get_note() WC 4.7.1

<?php
public static function get_note() {
	$onboarding_data = get_option( Onboarding::PROFILE_DATA_OPTION, array() );

	if ( ! isset( $onboarding_data['product_types'] ) || ! in_array( 'subscriptions', $onboarding_data['product_types'], true ) ) {
		return;
	}

	if ( ! self::wc_admin_active_for( DAY_IN_SECONDS ) ) {
		return;
	}

	$note = new WC_Admin_Note();
	$note->set_title( __( 'Do you need more info about WooCommerce Subscriptions?', 'woocommerce' ) );
	$note->set_content( __( 'WooCommerce Subscriptions allows you to introduce a variety of subscriptions for physical or virtual products and services. Create product-of-the-month clubs, weekly service subscriptions or even yearly software billing packages. Add sign-up fees, offer free trials, or set expiration periods.', 'woocommerce' ) );
	$note->set_type( WC_Admin_Note::E_WC_ADMIN_NOTE_MARKETING );
	$note->set_name( self::NOTE_NAME );
	$note->set_content_data( (object) array() );
	$note->set_source( 'woocommerce-admin' );
	$note->add_action(
		'learn-more',
		__( 'Learn More', 'woocommerce' ),
		'https://woocommerce.com/products/woocommerce-subscriptions/?utm_source=inbox',
		'actioned',
		true
	);
	return $note;
}