I am trying to remove parent category from the child category but nothing happens. I have a website made with the use of EDD. currently i have categories like below:
- angular-templates
- react-templates
- bootstrap-templates
In each categories, there are sub-categories/child-categories as below:
angular-templates
- angular-1
- angular-2
- angular-3
now if i go to my sub-category, url displays as below:
http://admin-pc/mysite/templates/category/angular-templates/angular-3/
And i want to remove angular-templates or whatever is the category name in url to remove and display url as below:
http://admin-pc/mysite/templates/category/angular-3/
Is it possible with add_rewrite_rule()?
I have achieved what i want with str_replace, but that will affect site's SEO, so that's not possible.