I have searched the web for a couple of days but can’t find a appropriate answer.
I use a Worpdress link structure like this: %category%/%postname% which results in /category/postname
But if I have posts in subcategories the Link is like /category/subcategory/postname
How can I define that the subcategory will NOT appear in the permalink?
As I mentioned before, I can’t find any advice to this on the web so I ask you for help.
Select Parent and Child both categories while adding a new post. This will strip child category in permalink.
For** subcategory will NOT appear in the permalink** — two ways
for getting rid of nested subcategory i think you have to install plugin which can easily make you change url of page, post etc. This one came up first on Google: http://wordpress.org/plugins/custom-permalinks/
You can rewrite you .htaccess if you are familiar with this.
Add the below line and try it:
RewriteRule ^category/(.+)$ http://www.site.com/$1 [R=301,L]
You must be logged in to reply to this topic.
Search for Stuff
Browse the Archives
Get the Newsletter
... or get the RSS feed