#39525 closed enhancement (fixed)
Send template candidates along with {$type}_template filter
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 4.8 | Priority: | normal |
| Severity: | normal | Version: | 4.8 |
| Component: | Themes | Keywords: | has-patch |
| Focuses: | template | Cc: |
Description
For many use case, it will be good, if the template candidates is used as second parameter in the {$type}_template filter.
Maybe the the type should be used as a parameter as well, but it is possible to get the type by calling current_filter() function.
Attachments (2)
Change History (7)
@mschadegg
12 months ago
#1
@mschadegg
12 months ago
- Keywords has-patch added
#2
@SergeyBiryukov
12 months ago
Hi @mschadegg, welcome to Trac! Thanks for the ticket.
A separate {$type}_template_hierarchy filter for template candidates was introduced in [38385], is it not sufficient in your case?
#3
@mschadegg
12 months ago
I have used that filter, to save the hierarchy as a property in a class, so I can use it in the other filter afterwards. So yes, it makes it possible to do what I want to accomplish, but I don't think it is a proper way to do it.
#4
@johnbillion
11 months ago
- Owner set to johnbillion
- Resolution set to fixed
- Status changed from new to closed
In 40057:
#5
@johnbillion
11 months ago
- Milestone changed from Awaiting Review to 4.8
Note: See
TracTickets for help on using
tickets.
Patch with template candidates as second parameter.