[buddypress-trac] [BuddyPress] #3741: BuddyPress should have theme compatibility

buddypress-trac at lists.automattic.com buddypress-trac at lists.automattic.com
Wed Aug 29 01:51:10 UTC 2012

#3741: BuddyPress should have theme compatibility
 Reporter:  johnjamesjacoby            |       Owner:  johnjamesjacoby
     Type:  task                       |      Status:  new
 Priority:  highest                    |   Milestone:  1.7
Component:  Theme                      |     Version:
 Severity:  critical                   |  Resolution:
 Keywords:  2nd-opinion needs-testing  |

Comment (by boonebgorges):


 This is great, John. For the most part, it works like magic. Awesome work.

 A couple things:

 - BP_Group_Extension plugins aren't fully working. To display content from
 the display() method, the _display_hook() method loads
 /groups/single/plugins.php, instead of /groups/single/home.php. But the
 logic of BP_Groups_Theme_Compat::single_content() doesn't account for the
 existence of plugins.php (which is, itself, a top-level template). I can
 imagine a couple different ways to approach this. On one end of the
 spectrum, the fact that plugins.php is a top-level template has always
 been annoying, and this might be a chance to fix that, by merging
 plugins.php into home.php. However, this will probably cause backward
 compatibility plugins with at least some plugins that reference
 plugins.php directly (rather than through BP_Group_Extension). So a safer,
 if less elegant, fix would be to take the opportunity in
 BP_Group_Extension::_display_hook() to add a filter to the theme compat
 template (this would be a reliable and lightweight way to ascertain that
 the current page needs plugins.php vs home.php). FWIW, this problem
 doesn't arise for /members/single/plugins.php, because it's not a top-
 level template - it's loaded by the logic in members/single/index.php.

 - You've copied and pasted the AJAX handlers from bp-default into bp-
 theme-compat/buddypress-functions.php. When I first loaded my rig with bp-
 default enabled, I got fatal errors about the duplicate function names. A
 lightweight way to solve this would be to change the function prefix for
 the bp-theme-compat versions of these callbacks.

 - s/bbp_/bp_

 - :)

Ticket URL: <https://buddypress.trac.wordpress.org/ticket/3741#comment:26>
BuddyPress <http://buddypress.org/>

More information about the buddypress-trac mailing list