Wordpress

How to remove the top bar in WordPress for logged-in users

Written by Ian Carnaghan · 7 sec read >

Edit the functions.php file in within your theme and add the following line to it

add_filter( 'show_admin_bar', '__return_false' );

This will remove the top bar when a user is logged-in.

Last Updated On April 06, 2018
Written by Ian Carnaghan
I am a software developer and online educator who likes to keep up with all the latest in technology. I also manage cloud infrastructure, continuous monitoring, DevOps processes, security, and continuous integration and deployment. In my spare time I teach undergraduate classes in web development. Profile

Leave a Reply

avatar
  Subscribe  
Notify of