Skip to:
Content
Pages
Categories
Search
Top
Bottom

Can we do includes?

  • Is there a way to add an include in a bbpress theme? I want to add some content in the pages that will change, and I just want to change one file instead of multiple ones.

    Something like this <?php include (TEMPLATEPATH . '/featured.php'); ?> from my wordpress theme. But have featured.php in my bbpress theme folder.

Viewing 5 replies - 1 through 5 (of 5 total)
  • I would put the absolute path and include it in the header.php of your theme if you want it on every page or just include it on specific files if you want it on certain pages.

    Trent

    I think it’s BBTHEMEDIR. You could also use bb_load_template() I think, which tries to load the filename you give it from the active theme folder.

    the absolute path worked fine, but BBTHEMEDIR and bb_load_template() didn’t do anything.

    thanks for the help.

    BBTHEMEDIR only takes you to the my-templates folder. I’m surprised that bb_load_template() didn’t work; ah well, you solved it anyhoo.

    I’ll admit I’m not that great a coder, so I may have done something wrong when I tried bb_load_template(). I’ll try again later and see, since having the whole address isn’t the best solution.

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