WordPress.org

Ready to get started?Download WordPress

Forums

Admin Bar Disabler
[resolved] Plugin Broken? (10 posts)

  1. rubinsandwich
    Member
    Posted 3 years ago #

    I really like the idea of this plugin, so I don't have to do it with a personal hack, but it does not appear to be working for me. In the settings page I get the following in the Roles blacklist box:

    Warning: in_array() [function.in-array]: Wrong datatype for second argument in /home/host/public_html/wp-content/plugins/admin-bar-disabler/admin-bar-disabler.php on line 322>Administrator

    This line repeats for Administrator, Editor, etc.

    I had the same issue in the whitelist box until I put in a capability in the Capabilities Whitelist box. I can't seem to get the blacklist error to go away though.

    I also don't really see how to select which roles are permitted and which are blocked. If I only want Admin, Editors, and Authors to see the Admin bar, how would I do that?

    http://wordpress.org/extend/plugins/admin-bar-disabler/

  2. lxsparks
    Member
    Posted 3 years ago #

    I was just about to post exactly the same thing about the function.in-array error.

    I was testing this out earlier today on a test website and it all worked fine, I installed WP on another site (which has a different hosting company) and the plugin won't work. I have tried it in WP 3.0.5 and 3.1 and each time it throws up the above mentioned warnings, so I think it must be something to do with the way the hosting system is set up.. Any ideas where to look?

  3. rubinsandwich
    Member
    Posted 3 years ago #

    OK, got the errors to go away by trying different entries into the capabilities input box. What specifically worked for me is putting "activate_plugins" in the whitelist box and "read" in the blacklist box. Save the settings and when it refreshes it should be OK. Once the errors are gone, I could delete the capabilities and everything works fine.

    My guess is that there is a lack of (or incorrect) default value somewhere. The developer still might want to look into this bug though.

    I've got the roles figured out too. The process is intuitive enough, but maybe it's the UI that makes it confusing. Maybe just some text to the right of each section saying "Select all rolls you want to have access to the Admin bar (cntl-click for multiple) and then click save" and the equivalent for the blacklist section. Minor, I know, but for the average Joe, it should be obvious how to work this thing.

    I'm not trying to be a nag or complainer, just offering tips to tweak and perfect your excellent plugin.

  4. Scott Kingsley Clark
    Member
    Plugin Author

    Posted 3 years ago #

    This plugin only works in WP 3.1, I'll post an update that fixes the warning you're seeing here.

  5. lxsparks
    Member
    Posted 3 years ago #

    I tried your workaround, rubinsandwhich, but no luck - still got the errors.

    Like I said above SKC - I got it working perfectly in my first set up but in the second (which is hosted with a different company) it has the errors, all I've got installed at the moment is WP 3.1 & the plugin.

  6. Scott Kingsley Clark
    Member
    Plugin Author

    Posted 3 years ago #

    Just put out a bug fix release, should be available once WP refreshes it's plugin directory in a few moments. Let me know if you both have any issues.

  7. lxsparks
    Member
    Posted 3 years ago #

    Update seems to have sorted it! Thanks Scott!

  8. Scott Kingsley Clark
    Member
    Plugin Author

    Posted 3 years ago #

    NP! Enjoy :) Also let me know if you'd like to see anything else in this plugin, or if you notice any other issues.

  9. rubinsandwich
    Member
    Posted 3 years ago #

    Scott, this is crazy fantastic support!

    Thanks for attending to this so quickly and so thoroughly. You rock.

  10. Scott Kingsley Clark
    Member
    Plugin Author

    Posted 3 years ago #

    NP, it's what I do for Pods so I'm used to keeping an eye out for bugs :)

    http://podscms.org/

Topic Closed

This topic has been closed to new replies.

About this Plugin

About this Topic