I created a custom post type on my site called Homes, which is working correctly. I created a custom taxonomy to go with it named Availability Category, and a category within that named Available Now. The taxonomy shows up in my Wordpress back end, but when I go view the category at homes/available-now, I get a 404 error.
Here is the code for my custom post type:
register_post_type( 'Homes',
array(
'labels' => array(
'name' => __( 'Homes' ),
'singular_name' => __( 'Homes Item' ),
'add_new_item' => __('Add New Homes Item'),
'edit_item' => __('Edit Homes Item'),
'new_item' => __('New Homes Item'),
),
'supports' => array('title', 'thumbnail', 'editor'),
'taxonomies' => array('homes-category'),
'public' => true,
'has_archive' => false,
'show_in_nav_menus' => TRUE,
'show_in_menu' => TRUE,
'rewrite' => array(
'slug' => 'homes',
'with_front' => false,
'hierarchical' => false,
),
)
);
And the code for my custom taxonomy:
register_taxonomy(
'homes-category',
'homes',
array(
'hierarchical' => true,
'label' => __( 'Availability Category' ),
'rewrite' => array(
'slug' => 'homes',
'with_front' => false,
),
)
);
Can anyone help with this? I've searched for hours for a fix and nothing I have tried so far has worked. Any help would greatly be appreciated.