skip to Main Content

How to create a custom post type template for a custom URL with taxonomy term in it? – WordPress

In my WordPress v6.0.2, I have a custom taxonomy country and a custom post_type interest. With post_type_link filter (another working function) and with the below function, I am rewriting custom post_type URLs as https://www.example.com/country_name/interest_term: add_filter('generate_rewrite_rules', 'country_cpt_generating_rule'); function country_cpt_generating_rule($wp_rewrite) { $rules…

VIEW QUESTION
Back To Top
Search