WordPress.org

Ready to get started?Download WordPress

Forums

Custom Post Type URL Structure (3 posts)

  1. dingguya
    Member
    Posted 1 year ago #

    Let's say I have a site with a custom post type called "locations". Each of those locations fall under a country and state. This is the URL structure I'm trying to accomplish:

    /locations/canada/british-columbia/<post-name>

    I would then want an index page for "locations" (listing all the locations) , "canada" (listing only the locations in canada) and "british-columbia" (listing only the locations in BC.

    Does anyone know how to accomplish this?

  2. OurWebSupport
    Member
    Posted 1 year ago #

    This can be achieved by using categories. For example you can make the category "locations". Make another category "canada" and using the Parent dropdown on the category page you can select "locations". You can do this for multiple levels. Let me know if this is what you intended.

  3. keesiemeijer
    moderator
    Posted 1 year ago #

Topic Closed

This topic has been closed to new replies.

About this Topic