adding webinaires post type

This commit is contained in:
Antoine M 2023-11-30 13:10:28 +01:00
parent dcd1d69ac0
commit cb5960b038

View File

@ -61,7 +61,7 @@ function create_posttype()
'show_in_rest' => true,
'menu_icon' => 'dashicons-pressthis',
'menu_position' => 2,
'supports' => array('title', 'editor', 'page-attributes'),
'supports' => array('title', 'editor', 'page-attributes', 'thumbnail'),
// 'supports' => array('title', 'custom-fields', 'editor'),
)
);
@ -144,11 +144,27 @@ function create_posttype()
'show_in_rest' => true,
'menu_icon' => 'dashicons-id-alt',
'menu_position' => 5.1,
'supports' => array('title', 'custom-fields'),
'supports' => array('title', 'editor', 'custom-fields', 'page-attributes'),
)
);
register_post_type(
'videos-webinaires',
array(
'labels' => array(
'name' => __('Webinaires', 'homegrade-theme__texte-backoffice'),
'singular_name' => __('Webinaire', 'homegrade-theme__texte-backoffice')
),
'public' => true,
'has_archive' => true,
'show_in_rest' => true,
'menu_icon' => 'dashicons-video-alt2',
'menu_position' => 5.1,
'supports' => array('title', 'custom-fields'),
'supports' => array('title', 'custom-fields', 'excerpt', 'thumbnail'),
)
);
}
add_action('init', 'create_posttype');