[wp-trac] [WordPress Trac] #18375: Post type templates
WordPress Trac
noreply at wordpress.org
Wed Oct 26 08:06:44 UTC 2016
#18375: Post type templates
-------------------------------------------------+-------------------------
Reporter: johnbillion | Owner: swissspidy
Type: enhancement | Status: closed
Priority: normal | Milestone: 4.7
Component: Posts, Post Types | Version:
Severity: normal | Resolution: fixed
Keywords: has-patch has-unit-tests needs-dev- | Focuses: template
note commit |
-------------------------------------------------+-------------------------
Changes (by swissspidy):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"38951"]:
{{{
#!CommitTicketReference repository="" revision="38951"
Posts, Post Types: Add support for post type templates.
WordPress has supported custom page templates for over 12 years, allowing
developers to create various layouts for specific pages.
While this feature is very helpful, it has always been limited to the
'page' post type and not was not available to other post types.
By opening up the page template functionality to all post types, we
continue to improve the template hierarchy's flexibility.
In addition to the `Template Name` file header, the post types supported
by a template can be specified using `Template Post Type: post, foo, bar`.
When at least one template exists for a post type, the 'Post Attributes'
meta box will be displayed in the back end, without the need to add post
type support for `'page-attributes'`. 'Post Attributes' can be customized
per post type using the `'attributes'` label when registering a post type.
Props johnbillion, Mte90, dipesh.kakadiya, swissspidy.
Fixes #18375.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/18375#comment:53>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list