diff --git a/wp-includes/post.php b/wp-includes/post.php
index 3716cba..cbab581 100644
|
a
|
b
|
function _add_post_type_submenus() {
|
| 1729 | 1729 | * @since 3.0.0 |
| 1730 | 1730 | * |
| 1731 | 1731 | * @param string $post_type The post type for which to add the feature. |
| 1732 | | * @param string|array $feature The feature being added, accepts an array of |
| | 1732 | * @param string|array $features The feature being added, accepts an array of |
| 1733 | 1733 | * feature strings or a single string. |
| 1734 | 1734 | */ |
| 1735 | | function add_post_type_support( $post_type, $feature ) { |
| | 1735 | function add_post_type_support( $post_type, $features ) { |
| 1736 | 1736 | global $_wp_post_type_features; |
| 1737 | 1737 | |
| 1738 | | $features = (array) $feature; |
| 1739 | | foreach ($features as $feature) { |
| 1740 | | if ( func_num_args() == 2 ) |
| 1741 | | $_wp_post_type_features[$post_type][$feature] = true; |
| 1742 | | else |
| 1743 | | $_wp_post_type_features[$post_type][$feature] = array_slice( func_get_args(), 2 ); |
| | 1738 | foreach ( (array) $features as $feature ) { |
| | 1739 | if ( func_num_args() == 2 ) { |
| | 1740 | $_wp_post_type_features[ $post_type ][ $feature ] = true; |
| | 1741 | } else { |
| | 1742 | $_wp_post_type_features[ $post_type ][ $feature ] = array_slice( func_get_args(), 2 ); |
| | 1743 | } |
| 1744 | 1744 | } |
| 1745 | 1745 | } |
| 1746 | 1746 | |
| … |
… |
function add_post_type_support( $post_type, $feature ) {
|
| 1749 | 1749 | * |
| 1750 | 1750 | * @since 3.0.0 |
| 1751 | 1751 | * |
| 1752 | | * @param string $post_type The post type for which to remove the feature. |
| 1753 | | * @param string $feature The feature being removed. |
| | 1752 | * @param string $post_type The post type for which to remove the feature. |
| | 1753 | * @param string|array $features The feature being removed, accepts an array of |
| | 1754 | * feature strings or a single string. |
| 1754 | 1755 | */ |
| 1755 | | function remove_post_type_support( $post_type, $feature ) { |
| | 1756 | function remove_post_type_support( $post_type, $features ) { |
| 1756 | 1757 | global $_wp_post_type_features; |
| 1757 | | |
| 1758 | | if ( isset( $_wp_post_type_features[$post_type][$feature] ) ) |
| 1759 | | unset( $_wp_post_type_features[$post_type][$feature] ); |
| | 1758 | |
| | 1759 | foreach ( (array) $features as $feature ) { |
| | 1760 | if ( isset( $_wp_post_type_features[ $post_type ][ $feature ] ) ) { |
| | 1761 | unset( $_wp_post_type_features[ $post_type ][ $feature ] ); |
| | 1762 | } |
| | 1763 | } |
| 1760 | 1764 | } |
| 1761 | 1765 | |
| 1762 | 1766 | /** |