wpseek.com
WordPress开发者和主题制作者的搜索引擎



_register_block_bindings_post_data_source › WordPress Function

Since6.9.0
已弃用n/a
› _register_block_bindings_post_data_source ( 没有参数 )
访问:
  • private
定义在:
文档:

Registers Post Data source in the block bindings registry.



源码

function _register_block_bindings_post_data_source() {
	register_block_bindings_source(
		'core/post-data',
		array(
			'label'              => _x( 'Post Data', 'block bindings source' ),
			'get_value_callback' => '_block_bindings_post_data_get_value',
			'uses_context'       => array( 'postId', 'postType' ), // Both are needed on the client side.
		)
	);
}