WordPress.org

Ready to get started?Download WordPress

Forums

Add Admin Bar to Custom Theme (5 posts)

  1. Jablesdactyl
    Member
    Posted 2 years ago #

    Hi, I wonder if anyone can help me. I've been making a custom theme for my site but I can't seem to get the admin bar to appear at the top. Any help would be greatly appreciated.

    Link to my site is http://www.littleblackpiano.co.uk/

    Thanks.

  2. Be sure you are using <?php wp_header();?> and <?php wp_footer();?> in your theme in order for admin to hook into the theme. http://codex.wordpress.org/Theme_Development

  3. Jablesdactyl
    Member
    Posted 2 years ago #

    Yeah, I'm using the gets for header and footer. Anything else I need to add? Specific function or css for the admin bar?

    Thanks.

  4. keesiemeijer
    moderator
    Posted 2 years ago #

    Yeah, I'm using the gets for header and footer.

    do you mean get_header(); and get_footer();?
    Try inserting the functions songdogtech is talking about:
    http://codex.wordpress.org/Function_Reference/wp_head
    http://codex.wordpress.org/Function_Reference/wp_footer

    Do you see something like this in the browsers source code?:

    <link rel='stylesheet' id='admin-bar-css'  href='http://test.dev/wp-includes/css/admin-bar.css?ver=20111209' type='text/css' media='all' />
  5. Jablesdactyl
    Member
    Posted 2 years ago #

    Amazing. Adding the wp_head and wp_footer worked perfectly. Thanks a million to both of you for all your help.

    James.

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags