Opened 14 years ago
Closed 13 years ago
#2649 closed defect (bug) (duplicate)
Add template hierarchy support into BuddyPress
Reported by: | DJPaul | Owned by: | DJPaul |
---|---|---|---|
Milestone: | 1.6 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Core | Keywords: | needs-patch |
Cc: | sorich87@… |
Description
WordPress' template hierarchy allows it to use specific template files for specific pages, or fall back to a default.
The attached patch is a first-pass of introducing the same to BuddyPress, built against the trunk. It has been taken out of a custom plugin and it has a designed limitation that it won't affect the main page templates which are always included by bp_core_load_template().
Most of the BP-Default theme uses bp_core_load_template() to load a "main" template file which then includes an appropriate secondary template to build the page; the latter is where I decided to patch.
Attachments (1)
Change History (10)
#2
@
14 years ago
- Summary changed from Add template hierarchy support into BuddyPress to [patch] Add template hierarchy support into BuddyPress
#3
@
14 years ago
May I have some feedback on this please? I'd like to put it in trunk. Specifically whether to fetch item IDs for BP Core components; at the moment it uses part of the URL to keep things compatible with all plugins.
#4
@
14 years ago
- Keywords needs-patch added; has-patch removed
After some discussion with John on IRC, I'm going to look to see if I can make a forwards-compatible patch to enable this to work with WP 3.1. The plan is to retain existing behaviour if not on WP 3.1.
v1