bbPress

Simple, Fast, Elegant

bbPress support forums » Installation

Could WP and bbpress share the same template ?

(12 posts)
  • Started 1 year ago by Alex123
  • Latest reply from samanathon
  • This topic is not resolved

No tags yet.

  1. Alex123
    Member

    Hi,

    I was wondering if there is a way to have bbPress uses the style-sheet etc. from the template
    I am using for WordPress, in order to have the same look and feel through the entire site.

    That would be a real integration ;-)

    Thanks
    Alex

    Posted 1 year ago #
  2. it is possible. Include the file wp-blog-header.php in the first line (after <?php) of your config.php. So, in every template file that calls bb_get_header() and bb_get_footer() you can replace them with get_header() and get_footer().

    In this way you're loading the WP header and footer ... and if you want to include some CSS specifically for bbpress you'll have to do it by means of a WP plugin or editing wordpress' header files.

    Posted 1 year ago #
  3. Alex123
    Member

    Thank you for your answer. It doesn't sound that difficult.

    Posted 1 year ago #
  4. gspark001
    Member

    how exactly do you include the blog-header in the config ?

    Posted 1 year ago #
  5. Alex123
    Member

    If I understood correctly your config.php should look like this:

    <?php
    <?php get_header(); ?>
    // ** MySQL settings ** //

    Posted 1 year ago #
  6. Alex123
    Member

    Correction

    <?php get_header();
    // ** MySQL settings ** //

    Posted 1 year ago #
  7. gspark
    Member

    added this as per others instructions, are they the same ?

    $bb->WP_BB = true;
    require_once( '../wp-blog-header.php' );

    Posted 1 year ago #
  8. No. That one looks to be correct, though, but it may need modification depending on the relational positions of your files.

    Posted 1 year ago #
  9. It can also be done by making the default bbpress theme look like your wordpress theme. I am almost done doing just that over at yourkahil.com

    For the most part everything is the same, only a handful of changes/tweaks to the template files.

    Posted 1 year ago #
  10. gspark
    Member

    i figured just to pull in header and footer that way if any theme or navigation modifications are done on WP end it should refelct on the bbpress end too, looking to switch nav bar when user is logged in

    Posted 1 year ago #
  11. gspark
    Member

    for some reason this code although works in pulling in WP header/footer i notice that i cannot access the admin, is this the correct code ?

    $bb->WP_BB = true;
    require_once( '../wp-blog-header.php' );

    update: ok i worked it out, needed the full path :)

    Posted 1 year ago #
  12. There is some great information on this here:
    http://bbpress.org/forums/topic/seemless-wordpress-integration

    Posted 1 year ago #

RSS feed for this topic

Reply

You must log in to post.

Code is Poetry.