WC_Admin_Assets::render_lost_connection_notice │ public │ WC 1.0

Render a #wc-lost-connection-notice mirroring WP core's own notice on post edit screens. See should_show_lost_connection_notice() for which screens get it.

Метод класса: WC_Admin_Assets{}

Хуков нет.

Возвращает

void. Ничего (null).

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

$WC_Admin_Assets = new WC_Admin_Assets();
$WC_Admin_Assets->render_lost_connection_notice();

Код WC_Admin_Assets::render_lost_connection_notice() WC 11.3.0

<?php
public function render_lost_connection_notice() {
	if ( ! $this->should_show_lost_connection_notice() ) {
		return;
	}
	?>
	<div id="wc-lost-connection-notice" class="notice error hidden">
		<p>
			<span class="spinner"></span>
			<strong><?php esc_html_e( 'Connection lost.' ); /* phpcs:ignore WordPress.WP.I18n.MissingArgDomain -- Reusing WP core translation. */ ?></strong>
			<?php esc_html_e( 'Saving has been disabled until you are reconnected.' ); /* phpcs:ignore WordPress.WP.I18n.MissingArgDomain -- Reusing WP core translation. */ ?>
		</p>
	</div>
	<?php
}