Top admin bar / toolbar not showing even when logged in, but empty top margin showing?

It looks like your theme is missing the wp_footer() function, but is containing the wp_header() function. I can replicate this behavior on the default themes, by removing wp_footer(). The HTML for the admin bar comes from this part in the Core code: add_action( ‘wp_footer’, ‘wp_admin_bar_render’, 1000 ); It’s usually informative to check out the default … Read more

Change home-url in dashboard

Try this. Even if you want to change “View Site” link then remove “site-name” and add “view-site” in get_node. Thanks. add_action( ‘admin_bar_menu’, ‘customize_my_wp_admin_bar’, 80 ); function customize_my_wp_admin_bar( $wp_admin_bar ) { $site_node = $wp_admin_bar->get_node(‘site-name’); //Change link $site_node->href = home_url().’/velkommen’; //Update Node. $wp_admin_bar->add_node($site_node); }

Exclude admin bar from showing avatar customization

In the WP_Admin_Bar::add_menus() class method you will find the actions: add_action( ‘admin_bar_menu’, ‘wp_admin_bar_my_account_menu’, 0 ); add_action( ‘admin_bar_menu’, ‘wp_admin_bar_my_account_item’, 7 ); and the two corresponding callbacks are using get_avatar(). To prevent the avatar changes in the admin bar, we can remove the foo_change_avatar filter before these callbacks and then add it again after the admin bar … Read more

Hide widgets/plugins from dashboard

WordPress SEO If you want to remove the admin menu: you can do that with: function hide_wpseo() { remove_action(‘admin_menu’, ‘zeo_options_menu’); } add_action( ‘init’, ‘hide_wpseo’); where it will be removed for all users. WordPress SEO by Yoast To hide the admin menu: and the admin menu bar: one can use: function hide_yoastseo() { remove_action(‘admin_bar_menu’, ‘wpseo_admin_bar_menu’,95); remove_menu_page(‘wpseo_dashboard’); … Read more

disable admin-bar search field for specific roles

Just in case anyone trips over this…here’s how you remove “search” and some examples of other things you can remove from the admin bar: public function remove_admin_menu_bar_items ($wp_toolbar) { $wp_toolbar->remove_node( ‘my-sites’ ); $wp_toolbar->remove_node( ‘wp-logo’ ); $wp_toolbar->remove_node( ‘new-content’ ); $wp_toolbar->remove_node( ‘view’ ); $wp_toolbar->remove_node( ‘logout’ ); //remove “logout” under “howdy” $wp_toolbar->remove_node( ‘user-info’ ); //remove “youraccount” under “howdy” … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)