Last active
August 2, 2017 09:36
-
-
Save Hexodus/acff3de9d178b417d72650cc695b9084 to your computer and use it in GitHub Desktop.
Reactivate Wordpress admin toolbar when it was hidden by the parent theme (idiots are everywhere!). In this case I reactivate it only for admins. Place this code in your functions.php (i.e. in your child theme's folder)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
if( current_user_can('administrator')) | |
add_filter( 'show_admin_bar', '__return_true' , 1000 ); | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment