As @N00b pointed out this can go in many answers and needs many concepts digestion.I will try to concise and give a sample answer with little info.
Since you have set has_archive
to true while registering post type , we can see all treatment post-type post on example.com/treatment/
. If we want to change this page to display just taxonomy categories list, we can use template page for this.
Create archive-treatment.php
in the root directory of the theme (If you know how to code and create child themes or the theme is your own ). Example archive-treament.php
looks like.
archive-treatment.php
<?php
get_header();
$args = array(
'show_option_none' => __( 'No treatment categories' ),
'style' => 'list',
'taxonomy' => 'treatment_category',
'title_li' => __( 'Treatment Categories' )
);
wp_list_categories($args);
get_footer();
Here wp_list_categories
outputs the categories available in the treatment_category
taxonomy and check all the arguments available.
If you just want to create page and use shortcodes there are many plugins out there that do this.
Reference: