Skip to:
Content
Pages
Categories
Search
Top
Bottom

bbPress 2.0 – conditional tags?

  • @mellomoose

    Member

    I use the plugin “Widget Logic” to manage where widgets show up. It uses conditional tags like “!is_page(‘name’)” to exclude widgets on specific pages.

    I can’t find or figure out the conditional tag for the bbPress plugin. I have a three column theme and want to clear the left sidebar so I can widen the center column where the forum lives.

    I use a blank text widget to keep the column from disappearing on other pages, but it’s a problem on the forum page — I think I’ve sort of bandaided myself into a corner.

    Is there a list of conditional tags specific to the bbPress plugin? Or maybe is there a better way to manage widgets?

    Any help is greatly appreciated.

    – Jeff aka MelloMoose

    http://mellomoose.com

Viewing 12 replies - 1 through 12 (of 12 total)
  • @johnjamesjacoby

    Keymaster

    Thanks for moving this here. :)

    Check the /bbp-includes/bbp-general-template.php file; there are a ton of _is_ functions.

    @johnjamesjacoby

    Keymaster

    Thanks for moving this here. :)

    Check the /bbp-includes/bbp-general-template.php file; there are a ton of _is_ functions.

    @mellomoose

    Member

    !bbp_is_forum() did the trick. Thanks!

    @mellomoose

    Member

    !bbp_is_forum() did the trick. Thanks!

    @dominornovus

    Member

    I use the Widget Logic plugin too to manage forum specific and blog specific widgets.

    I find this list useful: http://phpdoc.ftwr.co.uk/bbpress-plugin/bbPress/TemplateTags/_bbp-includes—bbp-general-template.php.html

    @dominornovus

    Member

    I use the Widget Logic plugin too to manage forum specific and blog specific widgets.

    I find this list useful: http://phpdoc.ftwr.co.uk/bbpress-plugin/bbPress/TemplateTags/_bbp-includes—bbp-general-template.php.html

    @zofar143x

    Member

    !bbp_is_forum() doesn’t work for me, maybe there is another function that is being used right now. Does anyone know which one? I want the widget to disappear on every thing from bbpress except for the user profile.

    @zofar143x

    Member

    !bbp_is_forum() doesn’t work for me, maybe there is another function that is being used right now. Does anyone know which one? I want the widget to disappear on every thing from bbpress except for the user profile.

    @zofar143x

    Member

    I had to use the following code in order to get it to work:

    !(is_post_type_archive( ‘forum’ ) || is_singular( array( ‘forum’, ‘topic’, ‘reply’ ) ))

    I needed to use is_post_type_archive() in order to get the widget to disappear from the forum index because none of the following tags worked:

    !is_page() (tried with slug, id and title)

    !is_single() (tried with slug, id and title)

    !bbp_is_forum()

    !is_page_template( ‘page-front-forums.php’ )

    as well as a bunch of other stuff I forgot. Does anyone know if there is a simpler tag that I can use?

    @zofar143x

    Member

    I had to use the following code in order to get it to work:

    !(is_post_type_archive( ‘forum’ ) || is_singular( array( ‘forum’, ‘topic’, ‘reply’ ) ))

    I needed to use is_post_type_archive() in order to get the widget to disappear from the forum index because none of the following tags worked:

    !is_page() (tried with slug, id and title)

    !is_single() (tried with slug, id and title)

    !bbp_is_forum()

    !is_page_template( ‘page-front-forums.php’ )

    as well as a bunch of other stuff I forgot. Does anyone know if there is a simpler tag that I can use?

    @nirzol1

    Member

    I confirm !bbp_is_forum() doesn’t work !

    But !(is_post_type_archive( ‘forum’ ) || is_singular( array( ‘forum’, ‘topic’, ‘reply’ ) )) work !

    @nirzol1

    Member

    I confirm !bbp_is_forum() doesn’t work !

    But !(is_post_type_archive( ‘forum’ ) || is_singular( array( ‘forum’, ‘topic’, ‘reply’ ) )) work !

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