Skip to content

Instantly share code, notes, and snippets.

@billerickson
Created September 3, 2016 21:44
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save billerickson/c3de75554a3cb5d8feb306fce2301a13 to your computer and use it in GitHub Desktop.
Save billerickson/c3de75554a3cb5d8feb306fce2301a13 to your computer and use it in GitHub Desktop.
<?php
// Admin Bar
add_theme_support( 'admin-bar', array( 'callback' => '__return_false' ) );
.admin-bar .site-container {
padding-top: 32px;
}
@media only screen and (max-width: 782px) {
.admin-bar .site-container {
padding-top: 46px;
}
}
@leepeterson
Copy link

@billerickson Curious about your approach to this using add_theme_support as opposed to some of the more common approaches, such as removing _admin_bar_bump_cb from wp_head when admin_bar_init runs, or when get_header runs. Would you mind sharing your thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment