| [ Index ] |
PHP Cross Reference of WordPress Trunk (Updated Daily) |
[Source view] [Print] [Project Stats]
Entity view configuration API. Builds the default view configuration for an entity and exposes it through the dynamic `get_entity_view_config_{$kind}_{$name}` filter so core and third parties can provide the configuration for a specific entity. The dynamic portions of the hook name are lowercased, e.g. `get_entity_view_config_posttype_page` for the `page` post type.
| File Size: | 756 lines (19 kb) |
| Included or required: | 0 times |
| Referenced: | 0 times |
| Includes or requires: | 1 file wp-admin/includes/plugin.php |
| wp_get_entity_view_config_hook_name( $kind, $name ) X-Ref |
| Builds the name of the dynamic filter that provides the view configuration for an entity. The entity kind and name are embedded in the hook name lowercased, so the hook follows the WordPress convention of lowercase hook names regardless of how the entity identifiers are spelled: the `postType`/`page` entity maps to the `get_entity_view_config_posttype_page` hook. return: string The filter name. param: string $kind The entity kind (e.g. `postType`). param: string $name The entity name (e.g. `page`). |
| _wp_get_default_posttype_form() X-Ref |
| Builds the default `form` configuration for post types that don't provide their own. It is a sensible default for `post`, `page`, and custom post types alike rather than being tailored per type. Post types that need a different shape can replace it entirely with a dedicated `form` through their own filter callback. It is intentionally NOT gated by `supports`. The registered fields are the single source of truth for what applies: each field is registered for a post type based on its `supports` (and related flags such as `theme_supports`), and the editor drops any form field whose definition is absent or whose `isVisible` returns `false`. return: array The default form configuration. |
| wp_get_entity_view_config( $kind, $name ) X-Ref |
| Returns the view configuration for the given entity. Builds the default configuration shared by all entities and then exposes it through the dynamic `get_entity_view_config_{$kind}_{$name}` filter — with the dynamic portions lowercased, see wp_get_entity_view_config_hook_name() — so that core and third parties can provide the configuration for a specific entity. return: array { param: string $kind The entity kind (e.g. `postType`). param: string $name The entity name (e.g. `page`). |
| _wp_get_entity_view_config_posttype_page( $data ) X-Ref |
| Provides the view configuration for the `page` post type. return: WP_View_Config_Data The updated view configuration container. param: WP_View_Config_Data $data The view configuration container for the entity. |
| _wp_get_entity_view_config_posttype_wp_block( $data ) X-Ref |
| Provides the view configuration for the `wp_block` post type. return: WP_View_Config_Data The updated view configuration container. param: WP_View_Config_Data $data The view configuration container for the entity. |
| _wp_get_entity_view_config_posttype_wp_template_part( $data ) X-Ref |
| Provides the view configuration for the `wp_template_part` post type. return: WP_View_Config_Data The updated view configuration container. param: WP_View_Config_Data $data The view configuration container for the entity. |
| _wp_get_entity_view_config_posttype_wp_template( $data ) X-Ref |
| Provides the view configuration for the `wp_template` post type. return: WP_View_Config_Data The updated view configuration container. param: WP_View_Config_Data $data The view configuration container for the entity. |
| Generated : Tue Aug 4 08:20:20 2026 | Cross-referenced by PHPXref |