remove_post_type_support( string $post_type, string $feature )
Remove support for a feature from a post type.
Description Description
Parameters Parameters
- $post_type
-
(string) (Required) The post type for which to remove the feature.
- $feature
-
(string) (Required) The feature being removed.
Source Source
File: wp-includes/post.php
function remove_post_type_support( $post_type, $feature ) { global $_wp_post_type_features; unset( $_wp_post_type_features[ $post_type ][ $feature ] ); }
Expand full source code Collapse full source code View on Trac
Changelog Changelog
Version | Description |
---|---|
3.0.0 | Introduced. |
User Contributed Notes User Contributed Notes
You must log in before being able to contribute a note or feedback.
Remove support for excerpts
This example removes support for excerpts in posts:
Remove support for post formats
This example removes support for post formats in posts:
Hide page visual editor if certain template is selected:
Expand full source codeCollapse full source code
Credit: https://wordpress.stackexchange.com/a/91644/138483