Forums

Join
bbPress Support ForumsThemesPHP if/else arguments

Info

PHP if/else arguments

  1. Hi all,

    I'm used to using conditionals within PHP if/else arguments such as is_page_template, is_page, is_front_page, and so on within WordPress. However, I'd like to apply some within my bbpress theme (to change the title of seperate sections of the forums) and I'd love to know which conditionals are appropriate/different within bbpress.

    Can anyone shed any light on this?

    Many thanks,

    Xander

  2. Hi,

    you need this function: bb_get_location()

    for example:

    if (!in_array(bb_get_location(), array('login-page', 'register-page'))) {
        login_form();
    }
  3. Hi Olaf,

    Thanks for pointing me in the right direction!

    Thanks also for your plugin solution for changing user's information fields, I actually found the solution on the finalwebsites' forums, but re-posted your fix in the forum here: http://bbpress.org/forums/topic/change-profile-information

    You're a life-saving bbpress & php wizard, and you deserve a shiny gold star for your good work.

  4. You must log in to post.