WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a custom post type called "Films" that is used to manage an entire film collection. I would like to create a custom box with a message that will sit on top of all of the posts when you click on the Films button in the wordpress admin area. Currently (and by default) there is no messaging, just an index of all the posts in this post type. I want a box to appear above all of the posts with my message.

The purpose of the box is to give admins of the site some direction on how to populate the films section. Any idea how I could go about this in wordpress? It is important to note that this message box should ONLY appear on the films custom post type, not on the dashboard or anywhere else.

share|improve this question
I tried something like this, but this is intended for the dashboard: wprecipes.com/… – JCHASE11 Mar 1 '12 at 19:34
up vote 2 down vote accepted
add_action('admin_notices', 'my_custom_notice');
function my_custom_notice()
    global $current_screen;

    if ( 'my_post_type' == $current_screen->post_type )
            echo "<h1>Whatever needs to be said</h1>";

Put this in your functions.php or plugin file. Replace 'my_post_type' with the name of your post type.

share|improve this answer
thanks! this was the solution – JCHASE11 Mar 2 '12 at 12:16

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.