BBPress 2.02 Conditional Tags for Widget Logic, Sidebars and MarketPress

Hello all,

NOTE: This is for BBPress 2.02 - the plug-in version. I have no clue if this is compatible with the stand-alone version.

I was pulling my hair out getting my sidebars right, making them look right with MarketPress and BBPress. Since the themes don't have specific sidebars for BBPress, it was really confusing to me.

I did a ton of research and finally got it working. it's actually pretty easy.

For the Blog widgets, I use the following conditional tags:

!mp_is_shop_page() &&!is_bbpress()

For the MarketPress widgets I simply use:

mp_is_shop_page()

(except for on the shopping cart widget, because I want that on the top of every sidebar on the entire site).

and for the BBPress Widgets I'm simply using:

!mp_is_shop_page()

I like having the forum categories show up in the blog sidebar, so for that specific widget I used only:

!mp_is_shop_page()

and for the Recent Forum Posts widget I used:

is_bbpress()

There may be better ways to do it, but this seems to work very well for me. Please reply if you have any suggestions or other cool tricks.

(Moderators - I chose the MarketPress plug-in for this post - there wasn't really a better option. Please change it if there's a better way for people to find this.)