Post Type Templates in 4.7
This caught my attention: in WordPress 4.7, all post types will finally be able to have the page templates feature that was previously only available on (the) pages (post type). You’ll just have to add an extra line to the top of the relevant template file that specifies the post types you want it to display. Pascal Birchler explains:
In addition to the
Template Namefile header, the post types supported by a template can be specified using
Template Post Type: post, foo, bar. Here’s an example:<?php /* Template Name: Full-width layout Template Post Type: post, page, product */ // … your code here
Personally, I’ve never really loved the page template feature in WordPress. But like many other features like it, it’s so darn useful sometimes that you really can’t fight it for long. It’s just so clearly an improvement over any alternative that has ever crossed my mind that I’ve no doubt that this feature being available for all kinds of content in a WordPress site will work out as a net win. When you don’t like it, you can simply not use it. When you need it, it’ll be there. That’s ideal.