Change “Enter Title Here” help text on a custom post type

I have a custom post type created for a directory that will end up being sorted alphabetically. I will be sorting the posts in alphabetical order by title, so I want to make sure that the Title is entered as last name/first name. Is there a way to change that default help text — “Enter Title Here” — in my custom post to something else?

5

There is no way to customize that string explicitly. But it is passed through translation function and so is easy to filter.

Try something like this (don’t forget to change to your post type):

add_filter('gettext','custom_enter_title');

function custom_enter_title( $input ) {

    global $post_type;

    if( is_admin() && 'Enter title here' == $input && 'your_post_type' == $post_type )
        return 'Enter Last Name, Followed by First Name';

    return $input;
}

Leave a Comment