function custom_rewrite_rules() {
add_rewrite_rule( '^art-classes/([^/]*)/([^/]*)/?$',
'index.php?product_cat=$matches[1]&location=$matches[2]',
'top' );
}
add_action('init', 'custom_rewrite_rules');
The $ at the end did the job. Not sure why.
Related Posts:
- Filter blog archive by category in URL
- Custom template for archive of a custom taxonomy
- Pagination on taxonomy archive pages breaks
- Adding tag’s featured image to tag archive
- Echo taxonomy name – second level
- Taxonomy term archive default loop returns 1 record instead of 8
- Calling an Archive Page with specific Tag/Tax ID
- Taxonomy.php inheriting first post
- All tag/category/custom taxonomy archives 404
- Same page for startpage and archive?
- How to share terms between two taxonomies?
- Taxonomy Rewrite Problem
- Taxonomy terms can’t find posts from archive.php or taxonomy.php
- Apply custom taxonomy archive template to children
- How to perform unit testing on proposed patches in Trac?
- Can the default “post tags” taxonomy be renamed?
- Add ‘Description’ to taxonomy ‘Quick Edit’
- get_categories for custom post type with a specific custom taxonomy attached
- get a specific taxonomy term name
- get_terms() How many is TOO many?
- Check if current term is a child of another term
- How to display child term of current term’s parent taxonomy?
- Sorting custom taxonomy causes menus error
- How to add terms to taxonomy with wp_insert_terms?
- Is there any difference between post in child term and child & parent terms?
- How to add automatically keyword to taxonomies when a post published, and assign them to the post
- Create and move terms for taxonomies
- Rewrite url / permalink for default archive – yearly / monthly
- How can I remove links from the function “get term list”?
- Alphabetical order in taxonomy.php
- Get Term names from WP Term Object
- functions to create term and child terms
- base directories / URL
- WordPress REST get all items without a taxonomy assigned
- Getting the parent from the wp_term_taxonomy
- How do I get the current tag out of a taxonomy?
- If search matches taxonomy
- Showing custom taxonomy column in taxonomy category listings immediately after create category
- Custom Field as Custom Taxonomy?
- Order wordpress taxonomy parent terms by their children count
- Modify the query method when adding category filtering function to the custom post list
- How to list taxonomy terms in reverse order?
- need to get postthumnails from a post whithin a category custom post type
- How to add Post Format Taxonomy Archive page in the menu?
- Create archive page for woocommerce attribute
- Group Post by Custom Taxonomy 2 under Custom Taxonomy 1
- Individual post. Meta_key, taxonomy or post status for separation?
- Taxonomy archive page WP_Query does not return get_the_permalink() or get_permalink() value
- Ordering Taxonomies / Changing term_id
- Custom Taxonomy Term Archive Page Template that Filters 2 or more Taxonomies
- How to show taxonomy image instead of taxonomy name on a list
- benefits of the table ‘wp_term_taxonomy’
- How to save a multiple checkbox array into a non-hierarchical taxonomy
- URL Rewrite with Custom Variables
- Redirect to another page using contact form 7? [closed]
- `get_terms()` with `child_of` and `childless` combined
- show ALL latest posts with archive.php on example.com/latest
- Add text to the end of each list item in wp_list_categories
- echo term name outside the loop, using term slug
- What are these undocumented arguments for register_taxonomy?
- Dynamic filtering of posts with custom taxonomies
- Sorting tags by name
- Modify output of wp_dropdown_categories to add term IDs to each option
- How to get terms from a custom taxonomies after WordPress 4.5.0
- Search Media by taxonomy
- Get Taxonomy name from “registered_taxonomy” hook
- In two-category searches, where does WordPress save the title of the 2nd category?
- Show only first child in dropdown
- Taxonomy archive template that shows posts from more than one taxonomy
- Custom Post Type + Custom Taxonomy = Archive Listing Page Problems
- Related terms – Terms that feature in post of current term
- Select query with two and two related taxonomies
- Taxonomy Dropdown Question
- Customize menu link for taxonomy in WP menu
- Change searching from world level to first letter
- How To Query For An Empty Taxonomy Field
- Is possible hide hierarchical select dropdown created by jetsmartfilters? (only visual issue)
- Custom Taxonomies Archive Page 404
- How to replace custom post type with custom taxonmy in permalinks
- I want to edit the tags template by adding text that displays all tags from the listed posts
- Archive for custom taxonomy
- Add specific content to a taxonomy results page
- Set the limit of taxonomy per page
- echo a tax term in loop
- How to manage the links of a new taxonomy
- Get taxonomy url, name, post count & image
- Custom taxonomy archive slug overwrites static page
- taxonomy terms are not populating select tag options
- Related Posts by taxonomy using Advance Custom Fields Plugin
- How to Display Child Taxonomy Posts
- Help me add Taxonomy to byline
- Filter custom taxonomy table
- How Can I List Categories by Date?
- Custom Taxonomy Page redirect 404
- Why is taxonmy-[taxonomyname].php not working?
- Adding Advanced Custom Fields to posts without hyperlinks
- Filter/Sort Post Form On Taxonomy page
- Add URL field to wordpress taxonomy
- Display taxonomy terms when adding a link in the admin
- Bulk import in custom taxonomy