Post Formats: admin UI + fallbacks for themes that don't support them
|Reported by:||alexkingorg||Owned by:|
|Component:||Post Formats||Keywords:||has-patch ui-feedback needs-codex|
There are several custom fields provided to put various bits of data into structured fields, allowing for custom output of those fields in a theme.
Note that the URL field is separate for Link formats so that URL will not be included in pingbacks until #18506 is accepted.
Creating structured data to support post formats makes them more powerful and allows themes to do more with them, but it also causes a potential backward compatibility problem for users that change to a theme that doesn't support post formats. To solve this problem, the following code can be used:
This looks at custom field data and the current theme's post format support, and where appropriate adds content to the post body.
For now I've kept the code in GitHub instead of attaching it here, so that pull requests can be created easily.
There was a great response to this from the community when we released it, so hopefully it can be considered for inclusion in core.
Change History (202)
comment:38 @helen — 2 years ago
- Keywords has-patch needs-testing added; needs-patch removed
comment:54 follow-up: ↓ 56 @Viper007Bond — 2 years ago
comment:69 in reply to: ↑ 67 @helen — 2 years ago
comment:79 in reply to: ↑ 78 @JerrySarcastic — 2 years ago
comment:120 follow-up: ↓ 121 @markoheijnen — 2 years ago
comment:128 follow-up: ↓ 130 @azaozz — 2 years ago
comment:152 in reply to: ↑ 150 @SergeyBiryukov — 23 months ago
- Resolution set to fixed
- Status changed from new to closed