How to remove parent from url slug?

Permalink
Hi, I would like some pages on my site to have a URL which does not include their parent pages. For example, if I have a page called brick-laying and it is organized under the services/ page, I would like its URL to be my-site.com/brick-laying and not my-site.com/services/brick-laying. How can I accomplish this? I would love a checkbox in the page properties that says 'Include parents in URL'. Or better yet, make the entire field in 'Paths and Attributes' be fully customizable.

Thanks

View Replies:
firepixel replied on at Permalink Reply
firepixel
What your suggesting is quite tricky I imagine, you can add an additional URL slug to any given page using the page properties dialogue, so you can definitely make pages accessible from the custom URLs you are suggesting.

If you want to make it the default page that is long, but to get it in the sitemap you could override the sitemap automated job and make it pull the first additional URL slug instead of the default URL (dependant on if a checkbox page attribute is set). I would then use the same code to set a canonical URL meta tag on each page.
InfiniteSandwiches replied on at Permalink Reply
That makes sense, but I've got links all of the site based on pulling each page's default URL. I was hoping for an easy solution, but it looks like I'd have to heavily modify the core page model. Searching that file I found 3 matches for 'insert into pagepaths'. I guess all 3 functions they are found in would need to be refactored. I'm also not sure how this would effect the overall functioning of the site.

This is a bummer since control over URLs is so critical to SEO. It seems to me that URLs should not be completely dependent on navigation and the visual organization of the site. Sure, the default URLs are fine, but the whole path should be customizable. C5's only validations should be to make sure that it is a unique identifier and a valid url.

Also, I find it cumbersome that the alternate paths are automatically reformatted. It would be nice to simply validate those as unique and valid urls since its main purpose is to handle legacy urls.

I guess the other option is to put all pages in the root and have a disorganized sitemap.
firepixel replied on at Permalink Reply
firepixel
You could put them in the root and split them by using different page types, and then customise your navigation code or use the page list block instead of autonav block in order to ignore the hierarchy?
InfiniteSandwiches replied on at Permalink Reply
Yeah, I think thats the best workaround, albeit messy.

Thanks!
InfiniteSandwiches replied on at Permalink Reply
Whatever its worth, I think I found an easy fix. Here's the explanation:

http://www.concrete5.org/index.php?cID=478723...