Unless there’s a reason the subcategory URL has to be www.webshop.com/slug/category1/subcategory1
, I would modify this to use a hash instead – i.e. www.webshop.com/slug/category1#subcategory1
This way you won’t break WordPress’s permalink structure and you can still easily use the hash with JavaScript so render the correct content on the page.
Related Posts:
- Newbie question: no index.php? in my plain wordpress permalink
- How to change redirection route to a php page for making it only accessible by logged-in members?
- parts of url disappear when using # inside href=”” [closed]
- Create custom permalinks to show Custom Post Type’s relationship?
- Nginx WordPress and another Web app URL structure
- Modifying WP URL handing code?
- How to deal with a GET variable of ‘name’?
- How to define a rule in functions.php that ONLY disables the default wp functionality that undesirably changes ‘&’ to ‘#038;’?
- Unable to display multiple parameters from url by javascript through shortcodes
- Current WordPress Page Title as Search Parameter into A Tag
- How does one make a URL return dynamic JSON with custom Content Type?
- I want url from a file in media using title file
- bloginfo url in javascript
- How can I add tinymce editor in WordPress with jQuery?
- How to speed up admin-ajax.php in wordpress
- JQuery not working on WordPress Admin page [closed]
- Customizer Show/Hide
- Page Reloads Before AJAX Request Finishes
- Colorbox ajax loading of outside HTML content works perfect on localhost but not on server
- How to make custom total price reactive in navigation
- Adding tawk.to code just before body tag on functions.php file
- How do I fetch all comments per post via WP REST API?
- Deregistering a script in WordPress seems impossible
- Slide in Panel WordPress Post
- Sending jsPDF documents to the server
- How to prevent those PHP variables from being cached on WordPress?
- Extract subdomain and relative address from a url
- Remove query string specific key value
- Ajax return code 400
- How can I add an alert (like the old javascript alerts) to my WP page?
- Pass PHP variable to JavaScript without inline JS
- Show post in slider
- How can I output a php value into a JS file within WordPress?
- Using shipped version of jquery
- Rename “Portfolio” slug?
- Putting PHP variables into javascript [duplicate]
- Bridging TinyMCE js and WordPress PHP?
- Echo URL of large version of Featured Image
- Why does WordPress remove my variables in the URL?
- Trying to implement Ajax comments in WordPress, getting WP error
- How to test nonce with AJAX – Plugin development
- How do I display a user’s previous orders as a select box option on a product?
- Simple Plugin with custom javascript wont work – no console error
- How does this WordPress Plugin (Thrive Comments) apply their custom comment sort? [closed]
- How can I use a modal window to display the current post in loops featured image?
- How to rewrite URL with PHP variables with htaccess to a normal looking URL?
- js file in root loading without
- class click counter save number
- Trigger popup in a php if/else statement
- Slider loading issue
- Static variable and add_rewrite_rule?
- AJAX request status 200 but no actual “response”
- Button not refreshing page
- Nesting if statements to echo only one string based on what tag was filtered?
- Ajax not working es expected (Returns 0)
- Use menu link or onClick to set a variable
- How to select the contents in the text view textrea in wp_editor?
- Creating a Multi-Level Associative Object Using AJAX
- WP functions in .js
- Adding custom directory and PHP files in wordpress
- How to change home or site url using action hooks or filter?
- Ajax – Call to undefined function get_option()
- Why do WordPress rewriites seem to work differently for posts vs pages?
- Performance impact of rewriting WordPress URLs
- Is sanitize_title_with_dashes formatting function too liberal (in terms of accepted characters)?
- Populate dropdown with Child Pages based on Parent Page chosen
- remove wp floating submenu in wp dashboard
- Displaying admin notices inside the block editor from rest_after_insert_{$this->post_type} hook
- search and replace preword from author
- How to prevent XSS alter custom global javascript object & methods in WordPress
- How to complete two other input fields, completed the first
- Status 400 for AJAX POST Request with admin-ajax.php
- How to inject variables into public-facing JS using wp_enqueue_script
- How to pass aa JS variable to PHP?
- Customize Theme comment template to Insert VoteUp and VoteDown buttons
- Ajax random number always the same
- Image upload via FormData API and AJAX is not working ($_FILES always empty)
- I have a problem in the order of enqueues while enqueuing stylesheets and scripts for a specific page in my function.php
- Dynamic content based on a URL parameter
- JS file work only in index page
- Need Help Fixing My Iframes [closed]
- wp_enqueue_scripts leads to error
- Javascript file is not working on single.php wordpress [closed]
- Colon is Missing In My Website Url in WordPress
- Changes in permalink structure in WordPress and how to apply to in-site links
- WordPress Persistent connection rule does not work for “posts”
- How to use $_GET function WordPress backend
- Append query string to all URL’s
- Integrating PHP into Javascript to display map markers with Google API – problem with wp_localize
- Save Search System
- dynamic dependent select dropdown
- custom rewrite rule help! Custom rewrite rules not applying to custom post type
- Passing UTM Parameters To Modify Page In WordPress
- How to send Ajax request from my plugin in admin dashboard?
- subdirectory index.php is not working
- Incorrect MIME type for assets with Valet
- Customizer: Multiple CSS styles on same element in Live Preview
- wordpress visual composer change grid builder post link
- Ajax load more button for comments wordpress
- How to register javascript variables in wp_localize_script?