Plugin: Add Sidebar
-
This extremely simple plugin adds a “bb_get_sidebar()” function to bbpress, similar to how WordPress comes with get_sidebar(). Once installed and activated, you can create a file named sidebar.php, put it in your theme directory, and invoke it from any theme page using bb_get_sidebar().
<?php
/*
Plugin Name: Add Sidebar
Plugin Description: adds bb_get_sidebar() to bbpress, similar to WordPress' get_sidebar()
Plugin URI: http://bbpress.org/forums/topic/1264
Plugin Author: Bob Hiler
*/
function bb_get_sidebar() {
bb_load_template( 'sidebar.php' );
}
?>
Please note that this simple plugin doesn’t automagically pull your WordPress sidebar. It’s simply a lightweight convenience function for making bbPress themes. I was surprised this wasn’t already included in template-functions.php, but bb_load_template() makes this super easy to add.
- You must be logged in to reply to this topic.