0

I want to change the title tag in the edit page, so that I can read the title of my edit page in my browser tabs:

function edit_admin_title_tag() {
global $post;
    $title_tag = '<title>'. $post->post_title .'</title>';
   echo  $title_tag;
}
add_action( 'admin_head', 'edit_admin_title_tag' );

How can I delete/overwrite the default title tag?

2

1 Answer 1

1

I found my the solution (filter hook admin_title) in Change page title in admin area

function my_admin_title($admin_title, $title) {
  global $post, $action;
  if($action == 'edit' ) {
    $admin_title_tag = '* ' . $post->post_title;
    return $admin_title_tag; 
  }
}
add_filter('admin_title', 'my_admin_title', 10, 2);

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

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