WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

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

Is there someway to change the title in wp-admin? Been looking all over google but no one seem to mention it.

I simply want to get rid of "— WordPress" and possibly change the "‹" into some other symbol.

Any ideas?

share|improve this question
up vote 14 down vote accepted
add_filter('admin_title', 'my_admin_title', 10, 2);

function my_admin_title($admin_title, $title)
{
    return get_bloginfo('name').' • '.$title;
}

You could also do a str_replace on $admin_title to remove "— WordPress" and change "‹".

Look at the top of the wp-admin/admin-header.php file to see what is going on by default.

share|improve this answer
    
Wonderful, thanks alot! – INT May 12 '11 at 6:01

All those answers above are unnecessarily complicated. I am a newbie and I found this out by experimentation.

$admin_title holds the title in admin-header.php, so simply remove — Wordpress from line 43-47 to remove "— WordPress" from the title. Play around in those lines to manipulate the title.

share|improve this answer
2  
This isn't a solution at all, because that file will be deleted during the next upgrade. You are just wasting your time. – toscho Feb 6 at 17:55

Here's how we've done it, in order to change only a specific custom post type:

/* edit the admin page title for a particular custom post type */
function edit_page_title() {
    global $post, $title, $action, $current_screen;
    if( isset( $current_screen->post_type ) && $current_screen->post_type == 'CUSTOM-POST-TYPE' && $action == 'edit' ) {
        /* this is the new page title */
        $title = 'Change to whatever you want: ' . $post->post_title;           
    } else {
        $title = $title .' - ' .get_bloginfo('name');
    }
    return $title;  
}

add_action( 'admin_title', 'edit_page_title' )
share|improve this answer
    
This should be add_filter() - but the rest is good in terms of working out which page you're on. – Dan Smart Apr 11 at 14:20

Your Answer

 
discard

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.