How to hide the top admin bar at the frontend of wordpress 3.4?
Answer Posted / Raj Kumar Srivastava
To hide the top admin bar at the frontend of WordPress 3.4, add the following code to your theme's functions.php file: nn`function my_admin_bar_hide() { if (!current_user_can('edit_theme_options')) { wp_dequeue_script('wp-admin-bar'); } } add_action('get_header', 'my_admin_bar_hide');`
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers