Skip to:
Content
Pages
Categories
Search
Top
Bottom

Scope error moving bp_group_list_admins()

  • Avatar of Matt Kern
    Matt Kern
    Participant

    @mattkern

    I am trying move bp_group_list_admins() to header.php and I am getting this error:

    Fatal error: Call to undefined method stdClass::get_administrators()

    I am pretty sure it is a scope issue but have not tracked it down yet.

    Any thoughts?

    Thanks

Viewing 3 replies - 1 through 3 (of 3 total)
  • Avatar of Matt Kern
    Matt Kern
    Participant

    @mattkern

    I still haven’t figured this one out if anyone has any ideas….

    Avatar of Burt Adsit
    Burt Adsit
    Participant

    @burtadsit

    That function relies on being in a group template object context. It isn’t in one in the header yet. That function only works in the theme content area after this: <?php if ( bp_has_groups() ) : while ( bp_groups() ) : bp_the_group(); ?>

    Avatar of Matt Kern
    Matt Kern
    Participant

    @mattkern

    Thanks Burt. That actually makes sense.

    Maybe I can resort to some CSS trickery to move it around.

    Thanks for the tip.

Viewing 3 replies - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.