A common request I receive regularly from my clients is to replace the “Howdy” from the WordPress admin bar with something more professional sounding like “Welcome”. WordPress doesn't provide a configuration option to do this, but if you add the following code to your theme's functions.php, you can easily replace Howdy with your choice of a new word.
add_filter( 'admin_bar_menu', 'replace_howdy', 25 ); function replace_howdy( $wp_admin_top_bar ) { $wp_my_account=$wp_admin_top_bar->get_node('my-account'); /* change 'Welcome' below to your choice of word */ $replacetitle = str_replace( 'Howdy', 'Welcome', $wp_my_account->title ); $wp_admin_top_bar->add_node( array( 'id' => 'my-account', 'title' => $replacetitle, ) ); }
Leave a Reply