[wp-trac] [WordPress Trac] #34278: Add support for embeds in the theme template hierarchy

WordPress Trac noreply at wordpress.org
Sun Feb 21 11:25:32 UTC 2016

#34278: Add support for embeds in the theme template hierarchy
 Reporter:  johnbillion                        |       Owner:
     Type:  task (blessed)                     |      Status:  reviewing
 Priority:  normal                             |   Milestone:  4.5
Component:  Embeds                             |     Version:  4.4
 Severity:  normal                             |  Resolution:
 Keywords:  has-patch 4.5-early needs-testing  |     Focuses:  template

Comment (by swissspidy):

 > I'd kind of prefer embed-post_format, honestly. For post types, embeds
 really don't make a heck of a lot of sense except in special cases, and
 filters would work better for adding special formats to go with the post
 types. For themes that support post formats though, special templates for
 embed per format make more sense.

 I tend to think the same, but post formats are currently not really taken
 into account in the template hierarchy. Themes are usually using
 `get_template_part()` for different post formats. `embed-format-{post-
 format}.php` could be an option though.

 Other than that, [attachment:34278.get_embed_template.patch] looks good.
 We just need to make sure nothing breaks when checking for `is_embed()`
 before `is_404()` and that customizing the embed template is actually easy

 That's why I think this should go hand in hand with #34561.

Ticket URL: <https://core.trac.wordpress.org/ticket/34278#comment:27>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list