Defining Custom WordPress Link Structure

Slingshot377

Newbie
Joined
May 2, 2009
Messages
27
Reaction score
2
Alright, so I have been trying to solve this issue for a while.

I am trying to achieve this link structure for the categories and posts on my website [http://www.MovieReserve.com]

Code:
Movies:
Action - http://www.moviereserve.com/movies/action/
Animation - http://www.moviereserve.com/movies/animation/
Comedy - http://www.moviereserve.com/movies/comedy/
Drama - http://www.moviereserve.com/movies/drama/
Fantasy - http://www.moviereserve.com/movies/fantasy/
Horror - http://www.moviereserve.com/movies/horror/
Romance - http://www.moviereserve.com/movies/romance/
Sci-Fi - http://www.moviereserve.com/movies/sci-fi/
Sports - http://www.moviereserve.com/movies/sports/
Suspense - http://www.moviereserve.com/movies/suspense/
Thriller - http://www.moviereserve.com/movies/thriller/

TV Shows:
Action - http://www.moviereserve.com/tvshows/action/
Animation - http://www.moviereserve.com/tvshows/animation/
Comedy - http://www.moviereserve.com/tvshows/comedy/
Drama - http://www.moviereserve.com/tvshows/drama/
Fantasy - http://www.moviereserve.com/tvshows/fantasy/
Horror - http://www.moviereserve.com/tvshows/horror/
Romance - http://www.moviereserve.com/tvshows/romance/
Sci-Fi - http://www.moviereserve.com/tvshows/sci-fi/
Sports - http://www.moviereserve.com/tvshows/sports/
Suspense - http://www.moviereserve.com/tvshows/suspense/
Thriller - http://www.moviereserve.com/tvshows/thriller/

I could solve this by setting the link structure to /%category&/%postname% but that doesn't work perfectly as although I have 2 parent categories (Movies and TV Shows) with the other categories stemming from them, I can't assign the same slug to two different categories.

I tried the Advanced Permalinks plugin, but that will only change the structure for posts and not the category itself.

I tried the Custom Permalinks plugin, but that will only change the structure of the category and not for the posts within the category.

I tried using both, but that makes both the category and the posts within them get an error (webpage not found for category and 404 for post).
 
Okay, that is really similar to what I need done, thanks :D


Basically what I need to do is get WP to allow 2 categories to have the same slug, as long as their parents are different.

This way, /movies/action and /tvshows/action would be able to coexist.


Does anyone know how to accomplish this?
 
with my method it can be done
2 cats -> movies and tvshows

all the subcategories you want, including action twice, but you have to set up the parent of that subcategory

after that you use the plugin i gave you and presto you have the urls you wish
 
All that plugin does is remove the category base /category/ from URLs. I have already done that. I still can't have /tvshows/action/ AND /movies/action/.

What I need to do is allow 2 categories to have the same slug while under different parent categories.

/tvshows/action/
/movies/action/

The BLUE is the parent category slug. They are different. No problem here.
The RED is the child category slug. They are the same. Wordpress does not allow this by default, as it thinks I will end up with one url being assigned to two categories. However, since I am using parent categories and only one child per parent category will have the slug, I will not end up with duplicate links. I just need Wordpress to allow me to assignt he same slug to both categories.
 
in my 2.8.3 wordpress i can do that, i have 2 main categories, named test1 and test2 and then i creat a subcategory for each of them, named test in both situations, AND IT WORKS

i don't understand what you're doing wrong, but i presume that you might not choose the parent when you create the category
 
Back
Top