WordPress.org

Ready to get started?Download WordPress

Forums

Permalink structure with /blog/ and custom post types help please? (2 posts)

  1. mattmikulla
    Member
    Posted 1 year ago #

    Hey all. I'm trying to set up my permalink and URL structure. I will have normal posts and custom post types.

    Blog:
    mysite.com/blog/

    Single Blog Post:
    mysite.com/blog/super-awesome-post

    Custom Post Type:
    mysite.com/testimonials/

    Custom Post Type Single:
    mysite.com/testimonials/mr-t/

    So I am currently using the plugin custom post types ui for my custom post types. I wouldn't might just registering them in the functions really but it's nice to not have to edit files.

    Anyway...I was under the impression that if I want my blog and posts to live in a directory off the main site I needed the following permalink structure:
    /blog/%postname%/

    However, when I view a testimonial /blog/ still in the URL.
    mysite.com/blog/testimonials/mr-t/

    Is there a way to handle this? I know there are options for custom post types but I haven't found any that work.

    Any advice would be much appreciated.

  2. Nick McBurney
    Member
    Posted 1 year ago #

    try /%category%/%postname%/ with 'blog' as the parent category. This will stop 'blog' showing up on pages such as your templates page and include it before your post titles.

    Nick

Topic Closed

This topic has been closed to new replies.

About this Topic