Add this code in function.php

add_action( ‘init’, ‘create_post_type’ );

function create_post_type() {
register_post_type( ‘acme_product’,
array(
‘labels’ => array(
‘name’ => __( ‘Products’ ),
‘singular_name’ => __( ‘Product’ )
),
‘supports’ => array( ‘title’, ‘editor’, ‘author’, ‘thumbnail’, ‘trackbacks’, ‘custom-fields’, ‘comments’, ‘revisions’, ‘page-attributes’ ),

‘public’ => true,
‘has_archive’ => true,
)
);
}

1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)
Loading...