Go to file
K. Adam White a830dbcab3 REST API: Support meta registration for specific object subtypes.
Introduce an `object_subtype` argument to the args array for `register_meta()` which can be used to limit meta registration to a single subtype (e.g. a custom post type or taxonomy, vs all posts or taxonomies).

Introduce `register_post_meta()` and `register_term_meta()` wrapper methods for `register_meta` to provide a convenient interface for the common case of registering meta for a specific taxonomy or post type. These methods work the way plugin developers have often expected `register_meta` to function, and should be used in place of direct `register_meta` where possible.

Props flixos90, tharsheblows, spacedmonkey.
Fixes #38323.



git-svn-id: https://develop.svn.wordpress.org/trunk@43378 602fd350-edb4-49c9-b593-d223f7449a82
2018-06-21 21:06:50 +00:00
src REST API: Support meta registration for specific object subtypes. 2018-06-21 21:06:50 +00:00
tests REST API: Support meta registration for specific object subtypes. 2018-06-21 21:06:50 +00:00
tools/i18n
.editorconfig
.gitignore Build/Tools: Update PHPCS ruleset for WP Core and related Composer setup. 2018-06-15 15:56:58 +00:00
.jshintrc
.npmrc
.nvmrc
.travis.yml
composer.json Build/Tools: Update PHPCS ruleset for WP Core and related Composer setup. 2018-06-15 15:56:58 +00:00
composer.lock Build/Tools: Update PHPCS ruleset for WP Core and related Composer setup. 2018-06-15 15:56:58 +00:00
Gruntfile.js
jsdoc.conf.json Build Tools: Fix JSDoc configuration include paths. 2018-06-14 12:45:06 +00:00
package-lock.json Emoji: Update Twemoji to version 11.0. 2018-06-20 04:20:32 +00:00
package.json Emoji: Update Twemoji to version 11.0. 2018-06-20 04:20:32 +00:00
phpcs.xml.dist Build/Tools: Update PHPCS ruleset for WP Core and related Composer setup. 2018-06-15 15:56:58 +00:00
phpunit.xml.dist
webpack.config.dev.js
webpack.config.prod.js
wp-cli.yml
wp-config-sample.php
wp-tests-config-sample.php