Forum

Thread tagged as: Problem, Runway

A little confusion with URLs / Routes in Perch Runway

I'm in the process of converting a site from Perch 2 to Perch Runway and all seemed to be going smoothly, until i noticed the page URLs are all wrong! But i'm not at all sure how to fix the issue.

So on the Perch 2 version of the site, all pages (even if they are nested under another, or another two as happens on eight occasions) have a URL with just the one slash in it (such as website.com/page-example)

The same site I've been rebuilding in Perch Runway has URLs more like: website.com/top-level-page/sub-page/sub-sub-page which is undesirable for this particular site.

I'm at a loss as to how i get the URLs to come out how i want them to and further, how i make it so when the site owner adds new pages in the future they will have the correct URLs. Any ideas?

Daniel Owen

Daniel Owen 0 points

  • 6 years ago
Drew McLellan

Drew McLellan 2638 points
Perch Support

You can just update the path in the page options.

I found that now! haha D'oh! However, it would be nice if it was an option somewhere for this to be automatic as i know i will have customers who will screw it up (by not adding the leading forward slash for example.

Drew McLellan

Drew McLellan 2638 points
Perch Support

You shouldn't have to routinely change the page path. Are you saying the pages are being created in the wrong place?

Well, if i create a page that is a sub page of a sub page, Perch Runway is adding the url of the two parent pages to the url by default. So i always get website.com/top-level/subpage/sub-subpage

There doesnt appear to be a way to tell it not to do this! So yes, i can change it in the page options from /top-level/subpage/sub-subpage to /sub-subpage but that is what i meant by i know i will have customers who will screw that up.

Drew McLellan

Drew McLellan 2638 points
Perch Support

Ok. When would you not want that?

Often! Haha! Several sites i work on want the url to be descriptive and not nested. That is generally something the owner has imposed (or you know, requested constantly!)

An example would be the site i'm working on right now where a page url is currently:

/hair-salon-insurance

But if it listed the top-level and subpage above it, it would be:

/hairdressing-beauty-insurance-cover/hairdressing-insurance/hair-salon-insurance

Would that not be a bit of a terrible url?

Drew McLellan

Drew McLellan 2638 points
Perch Support

It depends what your goal is - ordinarily a well structured URL should describe the page and its place within the site.

So something along the lines of:

/insurance/hairdressing/salons

Agreed (in that case!) That client wanted to go the way of each page having this long descriptive url.

Another case where i'd want a non nested url type is a blog site i've been working on, where they have a ton of articles under categories but the url should be just the name of the article itself (it is a similar kind of site to this: https://www.viralnova.com/)

Having recently used Craft (https://buildwithcraft.com/), i really like the flexibility urls have in it. I'm actually not a huge fan of the rest of it after having quite a few irritating issues but urls are done nicely.

Basically by default it would do the nested "top-level/subpage/subpage" style of url. If you don't want that, you tick a box that says "Entries in this section have their own URLs" and then there is a text box allowing you to define what makes up your url. In my case it would be [slug] which would just use what i currently input into "URL segment" when adding my page in Perch.

Drew McLellan

Drew McLellan 2638 points
Perch Support

You have the option to edit the URLs, so I think it amounts to the same thing. Sensible defaults with the option to customise.

It does amount to the same thing...sort of! Same end result but it means having to do it manually. However, as i said, customers will screw it up if they have to do it by hand. Meaning support calls are more likely and so on.