Quantcast
Channel: bbPress.org » All Posts
Viewing all articles
Browse latest Browse all 3638

Reply To: Sidebar reappear in topic and topic/

$
0
0

ok no problem

Normally you would have a bbpress.php that would contain

header stuff
while have posts loop stuff
do_sidebar stuff
do_footer stuff

Your theme has decided that the sidebar stuff will be in the footer stuff.

Now all this will work for non bbpress pages, so all we need to do is stop sidebars for bbpress pages.

so put back the footer line in bbpress.php

and then edit footer.php to make the first lines that were

<?php hybrid_get_sidebar( ‘primary’ ); // Loads the sidebar/primary.php template. ?>

</div><!– #main –>

<?php hybrid_get_sidebar( ‘subsidiary’ ); // Loads the sidebar/subsidiary.php template. ?>

change to

<?php if !bbpress() {hybrid_get_sidebar( ‘primary’ ); } // Loads the sidebar/primary.php template.?>

</div><!– #main –>

<?php if !bbpress() {hybrid_get_sidebar( ‘subsidiary’ ); }// Loads the sidebar/subsidiary.php template. ?>

essentially that code says ‘if the page is not a bbpress page ‘ the do the sidebar stuff the ‘!’ is a not statement and bbpress() checks if we are dispaying a bbprtess page

Give it a try, and come back and let me know if it works.


Viewing all articles
Browse latest Browse all 3638

Trending Articles