WordPress.org

Ready to get started?Download WordPress

Forums

Need Admin Bar's Full Code (11 posts)

  1. Hardeep Asrani
    Member
    Posted 1 year ago #

    Hey, I was trying to edit my admin bar and it caused some problems. please post full code of admin bar. I'm using latest wordpress version.

  2. esmi
    Forum Moderator
    Posted 1 year ago #

    What do you mean by "trying to edit my admin bar"? What exactly did you do?

  3. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi I tried to remove wordpress image menu option (full list) from admin bar. It's working fine on site but showing following error on admin panel:

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_admin_bar_wp_menu' not found or invalid function name in /home/content/01/10875201/html/wp-includes/plugin.php on line 487

  4. esmi
    Forum Moderator
    Posted 1 year ago #

    What exactly did you do? What files did you edit?

  5. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi i edited admin-bar.php

  6. esmi
    Forum Moderator
    Posted 1 year ago #

    Download a fresh copy of WordPress, extract wp-includes/admin-bar.php and upload that file to your site's wp-includes folder. Then promise to never, ever, edit a WordPress core file again - otherwise a kitten will die. ;-)

    Seriously, editing core scripts can bring down your entire site and/or open security holes for hackers to use. Just don't do it.

    If you want to add something to the admin bar, post here or in the Hacks forum asking to help to do it the correct way.

  7. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi thanks for the info...it's showing following on admin panel

    Warning: call_user_func_array() expects parameter 1 to be a valid callback, function 'wp_admin_bar_wp_menu' not found or invalid function name in /home/content/01/10875201/html/wp-includes/plugin.php on line 487

    Can you please reply with admin-bar.php's full code from your site's template. I'am on a slow network, it'll be hard to download full wordpress again. Thanks

  8. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi wait..I found it online...let me see if it works

  9. esmi
    Forum Moderator
    Posted 1 year ago #

    Sorry but no. We do not post whole chunks of core files here. You need to download a fresh copy of WordPress.

  10. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi it worked...can you help me with this now? http://wordpress.org/support/topic/how-to-remove-wordpress-menu-list-from-admin-bar

    I'm teen and news to wp. I edited and customized lots of files but not this one.

  11. Hardeep Asrani
    Member
    Posted 1 year ago #

    @esmi Great news... Instead of messing with codes. I hid that by adding following css :p

    .wp-admin-bar-wp-logo{
    display:none
    }

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags