BP Theme Authors: make sure your theme registers 'buddypress' support
The theme compatibility layer coming in BuddyPress 1.7 makes it so that any WordPress theme is BP-compatible. If you are an author of an existing theme that supplies its own BuddyPress templates, you can (and should) prevent BuddyPress from running theme compat in the context of your theme. You can do so by putting the following line in your functions.php:
add_theme_support( 'buddypress' );
Be sure that you put this line either in the global scope, or in a function that is hooked to 'after_setup_theme' with a priority of less than 100. See http://codex.wordpress.org/Function_Reference/add_theme_support and http://buddypress.trac.wordpress.org/ticket/4846#comment:4 for more information.
Here’s an explanation of why this change is necessary. In order to maintain full backward-compatibility with existing BP themes, theme compat only kicks in as a fallback. On any given page, BP first checks to see whether it can find the “old” templates in your theme directory (such as groups/single/members.php); if the old template is found, it is used, while if it’s not found, BP supplies the markup using theme compat. This means that, in the case of PHP templates, your legacy BP theme will work seamlessly with BP 1.7+.
In the case of CSS and JS, however, BP has no reliable way to know whether a theme is providing the necessary files to make your site look and work correctly. Theme compat errs on the side of caution and loads these static assets. But if your theme has also loaded its own version of these files, it may create conflicts in styling, and more importantly, it may cause certain AJAX events to be fired twice. add_theme_support( 'buddypress' ) tells BP that your theme will be taking care of CSS and JS (in addition to PHP templates).
Note that child themes of bp-default do not need to manually register ‘buddypress’ support; BP assumes it.
See #4846 for more details.
Une #BuddyPress 1.7 theme story : imathi.eu 2:30 am on February 25, 2013 Permalink |
[...] !! : 2012/02/25, Boone vient de publier un billet sur le blog de dev de BuddyPress informant les concepteurs de thèmes [...]
Important Notice For BuddyPress Theme Developers - WPMU.org 2:03 pm on February 26, 2013 Permalink |
[...] theme compatibility when your theme is active. Boone Gorges outlined how to do this in the latest post on the BuddyPress Development blog. You’ll want to add this line to your theme’s [...]
Important Notice For BuddyPress Theme Developers | BuildsiteUs 7:28 am on March 4, 2013 Permalink |
[...] theme compatibility when your theme is active. Boone Gorges outlined how to do this in the latest post on the BuddyPress Development blog. You’ll want to add this line to your theme’s functions.php [...]
Vernon Fowler 11:38 am on March 4, 2013 Permalink |
Glad I stuck with a child theme of bp-default. I’ll just move along and consider a theme update / change later…
Important Notice For BuddyPress Theme Developers | WordPress Community | powered by Mpress Studios 2:05 pm on March 11, 2013 Permalink |
[...] theme compatibility when your theme is active. Boone Gorges outlined how to do this in the latest post on the BuddyPress Development blog. You’ll want to add this line to your theme’s functions.php [...]
http://dentist-austin-texas.com/ 10:53 am on March 22, 2013 Permalink |
At this moment I am ready to do my breakfast, once
having my breakfast coming again to read additional news.
mercime 2:30 am on April 2, 2013 Permalink |
Additional information on BP 1.7 Theme Compatibility at http://codex.buddypress.org/developer-and-designer-information/
ashish kuamr 10:58 am on May 15, 2013 Permalink |
buddypress 1.7 and 1.6 is not supporting the salutation theme and menu and submenu options , do you have any idea?