Skip to:
Content
Pages
Categories
Search
Top
Bottom

[Resolved] Checking BuddyPress version

  • Profile photo of ghostpool
    ghostpool
    Participant

    @ghostpool

    Is there a way to check which version of BuddyPress the user has installed. With v1.7 I need to be able to include my custom BuddyPress functions for only pre 1.7 users.

Viewing 2 replies - 1 through 2 (of 2 total)
  • Profile photo of shanebp
    shanebp
    Moderator

    @shanebp

    Maybe this?

    `if ( version_compare( BP_VERSION, ‘1.7’, ‘<' ) )`

    Profile photo of ghostpool
    ghostpool
    Participant

    @ghostpool

    Excellent. That pointed me in the right direction. I modified it slightly so it compares versions with the “beta” in version number also.

    `if((version_compare(BP_VERSION, ‘1.7*’) == -1))`

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘[Resolved] Checking BuddyPress version’ is closed to new replies.