• Hi there,

    I’m having some trouble with WordPress category/subcategory archive URLs.

    For example, I want to be able to display this archive: http://faroutmagazine.co.uk/wp/track-of-the-day while keeping its parent category in the URL, making it http://faroutmagazine.co.uk/wp/music/track-of-the-day

    Previously, I was just getting a “This is embarrassing…” 404 message when accessing the /music/track-of-the-day URL (even though that’s the one that was appearing in the View option under categories in the admin section of WP).

    Now the View link in the admin area only shows me the /track-of-the-day URL, and this DOES display the category posts which is great, but I want it to include the parent category in the URL.

    Is there anything I can do to the functions.php file or any plugins I can add to make this happen? Please bear in mind that there are multiple subcategory archives on this site, and they should all contain the parent category in the URL.

    Any help would be greatly appreciated!

    Thanks,
    Ross

Viewing 3 replies - 1 through 3 (of 3 total)
  • Colin

    (@colinsafranek)

    Plus One!!!!!

    I can’t find anything addressing this issue. It seems basic. And I can’t see how it would disrupt any other rewrite rules in the wordpress permalinks structure.

    Have you found anything on this. I see no one understood your question on StackOverflow. And there doesn’t seem to be any WP documentation on this particular issue. Damn.

    – Colin

    As per the Forum Welcome, please post your own topic.

    Colin

    (@colinsafranek)

    Hey,
    @electrickiwi

    Actually I just realized that hierarchical subcategory archive permalinks are default in wordpress.

    I had a plugin called WP No Base Permalink installed to get rid of my category and tag base slugs in my archive permalinks. When I deactivated the plugin, category hierarchy suddenly returned to my archive permalinks.

    I have not yet found/tested another plugin for eliminating category/tag base slugs, but it turns out that I do not need that functionality for my current project.

    Instead I am using blog-articles and blog-tags for the standard categories and tags. Then I am using the plugin Types to create a custom post type and custom taxonomies. The Types plugin has an option in the advanced settings to set hierarchical taxonomy urls to true or false when creating a custom taxonomy.

    Then I found a plugin called Remove Taxonomy Base Slug to eliminate the taxonomy term from the base of the taxonomy archive urls. And this, thankfully, does not interfere with the hierarchical sub/category urls, OR the base slugs for standard tags and categories.

    Phew!

    I hope this helps!

    – Colin

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Show parent category AND subcategory name in subcategory archive URL’ is closed to new replies.