So in wp-includes/admin-bar.php there is a function that adds CSS styling to the page:
function _admin_bar_bump_cb() { ?>
<style type="text/css" media="screen">
html { margin-top: 28px !important; }
* html body { margin-top: 28px !important; }
</style>
<?php
}
I want to comment this out properly (either the function or the contents of the function, either one is fine) but not touch the core code. How would I do this?
I think you can do it like this:
Add this to your functions.php file. It will disable outputting of these inline styles in
<head>
section but the wp_admin_bar will be still available.If you would like to disable wp_admin_bar entirely, you can do it like this: