Support » Developing with WordPress » How to add Update Warning

Viewing 1 replies (of 1 total)
  • Mario Santos


    Hello @jccpaymentsystems!

    I guess it depends on where you want to show that warning. If I am not mistaken, when there is a new version available of any plugin installed, a warning like the following one is shown by default.

    If that is not enough for your use case, there is also the admin_notices hook, where you can add a more detailed message at the top of your page. Something like:

    function custom_admin_notice() {
        <div class="notice notice-info is-dismissible">
            <p><?php _e( 'Please update my plugin', 'sample-text-domain' ); ?></p>
    add_action( 'admin_notices', 'custom_admin_notice' );

    Hope that works for you!

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.