• I used the following to register the post type

    function create_estate_sales_post_type() {
    $eslabels = array(
    'name' => 'Estate Sales',
    'singular_name' => 'Estate Sale',
    'add_new' => 'Add New Sale',
    'add_new_item' => 'Add New Sale',
    'edit_item' => 'Edit Sale',
    'new_item' => 'New Sale',
    'all_items' => 'All Sales',
    'view_item' => 'View Sale',
    'search_items' => 'Search Sales',
    'not_found' => 'No Sales Found',
    'not_found_in_trash' => 'No Sales found in Trash',
    'parent_item_colon' => '',
    'menu_name' => 'Estate Sales',
    );
    register_post_type( 'estate-sales', array(
    'labels' => $eslabels,
    'has_archive' => true,
    'public' => true,
    'supports' => array( 'title', 'excerpt', 'thumbnail' ),
    'taxonomies' => array( '' ),
    'exclude_from_search' => false,
    'capability_type' => 'post',
    'rewrite' => array( 'slug' => 'estate-sales' ),
    )
    );
    }

    single-estate-sales.php does not work, archive-estate-sales.php does not work.

  • The topic ‘Custom Post Type Template not working’ is closed to new replies.