WordPress at a glance
function is not described

_post_type_meta_capabilities() WP 3.1.0

Store or return a list of post type meta caps for map_meta_cap().

This is an internal function for using it by WP core itself. It's not recommended to use this function in your code.

No Hooks.


null. Null. Nothing.


_post_type_meta_capabilities( $capabilities );
Post type meta capabilities.


  • Global. Array. $post_type_meta_caps Used to store meta capabilities.


Since 3.1.0 Introduced.

Code of _post_type_meta_capabilities() WP 5.7.1

function _post_type_meta_capabilities( $capabilities = null ) {
	global $post_type_meta_caps;

	foreach ( $capabilities as $core => $custom ) {
		if ( in_array( $core, array( 'read_post', 'delete_post', 'edit_post' ), true ) ) {
			$post_type_meta_caps[ $custom ] = $core;