DISCLAIMER: this post is older than one year and may not be up to date with latest WordPress version.

When creating a WordPress site for a non tech-savvy user, it can be very useful to be able to display a custom message on the post editor page. Here’s a very simple hook to do it.

Copy the following snippet and edit the message on line 5. Once done, paste it on your functions.php file and save.

function wptutsplus_text_after_title( $post_type ) { ?>
    <div class="after-title-help postbox">
        <h3>Using this screen</h3>
        <div class="inside">
            <p>Use this screen to add new articles or edit existing ones. Make sure you click 'Publish' to publish a new article once you've added it, or 'Update' to save any changes.</p>
        </div><!-- .inside -->
    </div><!-- .postbox -->
<?php }
add_action( 'edit_form_after_title', 'wptutsplus_text_after_title' );

Thanks to WP Tuts for this great tip!

Tags

One Comment

  1. I’ll say the same thing here that I commented on the original article’s website. I do not understand why you would do this. You should use the contextual_help filter and utilize the Help drop down tab which is designed precisely for something like this. This just clutters the edit screen for something people really won’t need to see every single time.

    It’s a good tip on how to use a hook to tap into the action right after the title, but I don’t agree with the usage.

Leave a Comment

Your email address will not be published. Required fields are marked *