WC_Post_Types::rest_api_allowed_post_types() public WC 1.0
Added product for Jetpack related posts.
{} Это метод класса: WC_Post_Types{}
Хуков нет.
Возвращает
Массив.
Использование
$result = WC_Post_Types::rest_api_allowed_post_types( $post_types );
- $post_types(массив) (обязательный)
- Post types.
Код WC_Post_Types::rest_api_allowed_post_types() WC Post Types::rest api allowed post types WC 5.0.0
public static function rest_api_allowed_post_types( $post_types ) {
$post_types[] = 'product';
return $post_types;
}