Customize category URL

I figured this out by reading this article. It was very simple, all I had to do was: Change the $talks_cat_args[rewrite][slug] from ‘talks’ to ‘talks/category’ (which I had tried before) but missed… Make sure register_taxonomy is before register_post_type. Read the article, but it’s basically because of “how WP_Rewrite works as the process of deciphering permalinks … Read more

Pagination always adding “Next” link when results come from Custom Post Type WP_query

/doctors/ is a post type archive, so we can check if that query is being run in the pre_get_posts action via the conditional tag is_post_type_archive( ‘doctors’ ) and modify those queries accordingly. WordPress passes the query object to the function by reference ( $query in this example ), so we can modify the query vars … Read more