Add custom admin notice
-
Hi,
I need to checking some WC setting field has value,if is empty it will show notice in woocommerce admin setting page.So, I trying to use “add_custom_notice”, but it will show an error:
Call to undefined function add_custom_notice()…
function test_notice() { add_custom_notice( _test, $notice_html ); $notice_html = ("<h1>123</h1>"); } add_action( 'woocommerce_init', 'test_notice' );
BTW,I create the plugin for this code and I’m not sure what the hook to use.
- The topic ‘Add custom admin notice’ is closed to new replies.