Ok, that sounds like a rather confusing title, let me explain.

I have created a custom post type (CPT) and I want to add some summary information about the posts of that post type above their listing (where the filter and bulk action buttons are), the page in question would be:


Is there a hook for this ? Since I don’t really know what to call this area, i am not finding anything doing any further searches.

  • What code have you tried so far? What theme are you using? – Brad Dalton Jan 13 '14 at 22:42
  • @BradDalton theme, which is self developed in this case, has nothing to do with it, it is an admin screen which im trying to edit; not a frontend one. Thanks for trying to help out though. – Ronnieinspain Jan 13 '14 at 23:05

You can use the admin_notices action for that:

function wpa_admin_notice() {
    $screen = get_current_screen();
    if( 'your_post_type' == $screen->post_type
        && 'edit' == $screen->base ){
        <div class="updated">
            <p>Here is some text</p>
add_action( 'admin_notices', 'wpa_admin_notice' );

Change your_post_type to whatever your custom post type slug is. Also see get_current_screen for more info on that function.

  • thanks, should have thought about admin_notices ! Thanks again, saved me hours of wracking my brain :) – Ronnieinspain Jan 13 '14 at 23:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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