Reputation: 11
I'm using categories to construct my portfolio in this way:
Portfolio has an ID of 4, Web is 23, Animation is 27, and Print 31.
I have my URL's set /%category%/%postname%/ in the Permalinks, but when I add a post to say both Portfolio and Animation it won't show the /animation/ in the URL because Portfolio is a lower ID than Animation. How can I tell WordPress to ignore this? I'm sure I saw a plugin somewhere but can't remember where. The only other fix would be not to choose the parent category for the post and only choose the child, but this too has its problems.
Any ideas? I'm pretty sure there is a plugin, but I'm open to ideas.
Thanks
Upvotes: 1
Views: 2546
Reputation: 347
You can try this code
<?php
$category=get_the_category();
echo get_category_parents($category[0]->cat_ID , TRUE, ' » ');
?>
Upvotes: 0
Reputation: 2437
Hikari Category Permalink is a fork of sCategory Permalink.
Red permalink links appear on mouse-over in the categories box which let you define the category to be used in the URL.
The example would result in something like: my_site.com/category/ciencia/my_post
Upvotes: 0
Reputation: 161
I think the best way to do what you want it's to transform your post to page.
Take your page:
Upvotes: 0
Reputation: 2358
I think you are looking for this.
http://wordpress.org/extend/plugins/scategory-permalink/
Upvotes: 1