So after many trials and errors, I found I had to create a specific rewrite rule to go into my functions.php, one that handles post type ‘videos‘ and the category (taxonomy) ‘videos_category‘:
add_filter('init', function() {
add_rewrite_rule(
'^videos/([^/]*)/([^/]*)/(\d*)?',
'index.php?videos_category=$matches[1]&p=$matches[2]&paged=$matches[3]',
'top'
);
});
I also found this plugin to be really helpful for viewing my rewrite rules:
https://wordpress.org/plugins/rewrite-rules-inspector/
Related Posts:
- custom post type paging not working past page 3
- Paginated Taxonomy Term Archive including one post per term
- WP_Query search posts by custom post type and custom taxonomy
- Order WordPress Custom Taxonomy Pages & Pagination Not Working
- Taxonomy Archive: Display only one post per term from separate custom taxonomy
- Pagination : How to remove /page/x/ after a ‘POST’ action on a form returning to page 1
- Pagination for Custom Taxonomy Page [duplicate]
- Custom taxonomy rewrite give pagination 404
- Different options per post type in WP_Query
- Foreach loop returning more than one item when querying taxonomy
- custom taxonomy pagination 404 error
- set object terms after some some time of published post – functions.php
- pagination problem listing custom post types of taxonomy in wordpress
- Custom Taxonomy – fields
- The most recent post of custom taxonomy
- Pods pagination erases my sub menu
- Values inside a custom field to determine which category posts to display
- Pagination not working on homepage
- Exclude a category from WP_Query
- Get Custom Taxonomy ID within loop
- get_query_var() not working in pre_get_posts
- query multiple taxonomies
- Get custom post type by category in a page template
- Pagination Doesn’t Work
- Numeric pagination custom post type
- Categories under custom post types doesn’t show properly
- Sorting a list of posts displayed under a list of associated terms (which should be sorted without initial articles)
- Sort the main query in subcategories/terms?
- Custom Taxonomy List links being re-written
- Want to filter only parent post in admin area
- Custom Taxonomy and tax_query Issue?
- Pagination Issue: Custom Post Type In Index
- Custom post query by taxonomy
- Separate Posts and Custom Post Type in Custom Taxonomy archive template
- Group custom posts by custom taxonomy names
- How can i skip same post from taxonomy term?
- Pagination for custom php code
- Pagination on a custom post type loop
- Page vs Custom Post Types Differences/Issues
- Wrong request query on cpt and tax
- Search / Filter posts on Title/Content OR Tags
- Custom loop with multiple taxonomy queries
- Why are taxonomy terms not saving when using custom meta boxes with radio button taxonomy selectors?
- creat filter with wp_query
- What’s the WP way to load remaining custom posts?
- Custom post type editor with dynamic selects, one drop down populating a second second drop down not working
- Pagination with custom query, custom search form, single and pages, ajax and no plugins
- WP the_posts() on single-cars.php get category link
- tax_query not working in template
- Cant get paginations on single.php to work with my custom post types
- Pagination Not Working for Custom Taxonomy with Custom Query – 404 Error
- How can I group posts by months and years?
- Custom WP_Query always respond with 200 status even when no entry
- Can’t use pagination with custom taxonomy
- Creating two loops based on different logic
- WP_Query parameter conflict
- Show message when query has no posts
- How to show all taxonomies within custom post type loop
- get_terms() returns Trying to get property of non-object error for custom taxonomy
- Custom Post Type Archive Pagination
- List all Custom Post Type posts excluding certain Taxnomy term
- Taxonomy rewrite pagination 404
- Query custom posts from custom taxonomy
- Custom post type pagination error
- Related “custom post type” using “custom taxonomy”
- Page that lists publications by classifying them by taxonomy
- Custom post type paging return home page
- custom post type and a “sticky” position taxonomy
- Display post count for a specific month
- Assigning categories to custom post types via a front-end form; only works for native post type
- wp_post_delete is deleting all offices
- WP_Query to display number of custom post type filtered (order by) taxonomy
- Live search by custom tag
- Why is my loop not populating the page with my custom taxonomy terms from my custom post type?
- Show parent category and subcategory once in while loop
- WP_Query based on ‘s’ and tax_queries
- Ajax load more inside custom post type taxonomy
- How to get the posts that my following users are liked?
- Create a custom wp_query from a specific custom post type with specific taxonomy
- Show tags of custom post types in WordPress
- Problems with the WP_Query query for a Custom post type
- Display all Custom taxonomy terms and their relevant custom posts
- CPT Efficient way to display posts from different categories with custom query
- Custom taxonomy in custom post type archive with pagination
- Get archive of posts separated by taxonomies and subtaxonomies
- why custom post archive gives always no more than 10 posts despite of paging settings?
- Query Pulling the same post twice
- Post data in separate divs with incrementing class using WP_Query
- Pagination for a Custom Taxonomy
- WP Query WordPress Post Type with the same Taxonomy name
- Pagination URL order
- How to list groupings and keep pagination
- How to retrieve taxonomy terms of the current custom post?
- Building a List of Posts grouped by custom taxonomy as the section header only to be displayed if at least one post is in that tax
- Listing all custom post types using a specific term on the said term’s template page, in groups
- How to Get The Taxonomy Term in Custom Post Type Loop Inside a Wp Query
- Archive page – problem with pagination
- display custom post type from register taxonomy
- Store custom post type with JSON content
- WP Query Conditionally query meta and taxonomy