Skip to content

trepmal.com

  • Home
  • Plugins
  • Github
  • Me on WP.org
  • Donate

Categories

  • WordPress Bits (149)
  • Uncategorized (11)
  • Scripts (5)
  • Tidbits (5)
  • Fun (3)

Tags

  • wordpress (30)
  • administration (16)
  • plugin (9)
  • free download (8)
  • functions.php (8)

Year

  • 2018 (8)
  • 2016 (2)
  • 2015 (4)
  • 2014 (19)
  • 2013 (11)

Action Hook: admin_notices

Simple Admin Notices

If you need to add a simple warning or error notice to the WordPress admin area, or if you just to to make a small announcement to the site users, you can do so pretty easily.

add_action('admin_notices','simple_announcement');
function simple_announcement() {
    ?><div class="updated">
    <p>hello</p>
    </div><?php
}
Posted on March 20, 2011March 1, 2012Categories WordPress BitsTags admin notices, administrationLeave a comment on Simple Admin Notices
Proudly powered by WordPress