What function actually renders the wp_admin_bar? And how can I call it? I want to print out just the nodes / DOM for the actual menu. It would end up rendering something like this:

<div id="wpadminbar">
    <div class="quicklinks">

I couldn't find it in the documentation anywhere.


1 Answer 1


WordPress admin bar is rendered by render() method in WP_Admin_Bar class, also you may need to check wp_admin_bar_render(), it add few hooks before and after rendering and also calls this method


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.