Im trying to enable the admin bar on all pages but one titled "Registration" on my Wordpress site..The function below isnt working.. Any ideas? Thanks!!
show_admin_bar( true );
if (is_page( 'registration' )) {
show_admin_bar( false );
}
Try adding this little piece of code in to the page:
add_filter('show_admin_bar', '__return_false');
add_action('after_setup_theme', 'remove_admin_bar');
function remove_admin_bar() {
if (is_page( 'registration' ) && !is_admin()) {
show_admin_bar(false);
}
}
add_filter('show_admin_bar', '__return_false');
Well, since my previous suggestion did not suit your needs, have you tried this plugin?
http://wordpress.org/plugins/wp-toolbar-removal/
Alternatively, you can check the functions.php file and search for the show_admin_bar function. Upon doing that, you can input the code shown above in either my post or Mooed's post.