Skip to:

bbPM admin menu not working at all

  • Ben L.


    You can download a before-alpha copy at

    The problems I’m having are that

    1. When I activate the plugin, it doesn’t know about the “bb_is_user_logged_in()” command
    2. And when I delete that command from the plugin, it never finds BB_IS_ADMIN to be true.

    Fatal error: Call to undefined function bb_is_user_logged_in() in J:wwwhtdocsbbpress-stablemy-pluginsbbpm.php on line 20

Viewing 1 replies (of 1 total)

  • _ck_


    I am not sure about the loading order of your plugin but keep in mind that stuff like bb_is_user_logged_in() is only available when bbPress is fully initialized.

    Essentially you cannot execute anything but the most basic independent code until do_action('bb_init' happens.

    So you have to hook bb_init, ie:


    and THEN your function can check bb_is_user_logged_in.

    BB_IS_ADMIN is a constant so be sure to use DEFINED to test it and not directly or you’ll get an error

    if (defined('BB_IS_ADMIN')) {

    (also, BB_IS_ADMIN means if you are in the admin menu, not if the user is an administrator – not sure if you knew that)

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.
Skip to toolbar