Opened 5 years ago
Last modified 5 years ago
#54523 new enhancement
inherited custom template hierarchy
| Reported by: | grosfaignan | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Review |
| Component: | Themes | Version: | 5.8.2 |
| Severity: | normal | Keywords: | |
| Cc: | Focuses: | template |
Description
hi,
i would to make a feature request on worpdress.
it would be a good idea to give us the possibility to create custom template hierarchy in worpdress.
example, i would to create a profile page who inherit author template hierachy.
the possibiltiy to build something like a class who extends the author class would be usefull…
better... the possibility to create custom template hierarchy with custom rules could be a good idea...
Change History (2)
Note:
See TracTickets
for help on using tickets.
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
Templates apply to what is retrieved for display on the front end, which is from the post table, so if you make your author a post type you can use the existing template hierarchy to make a template for that post type. Template parts have a fallback mechanism, which is sort of like inheritance. It could be better than making a template because it affects only part of the page.
For related tickets about the template algorithm, see #48175 and #43597
Otherwise, authors in the user table are only shown by core in the admin, and not displayed with a template.