Jump to:

23480 Posts in 18951 Topics by 2878 members

General Questions

SilverStripe Forums » General Questions » URL of older page versions

General questions about getting started with SilverStripe that don't fit in any of the categories above.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Page: 1
Go to End
Author Topic: 421 Views
  • rainerh
    Avatar
    Community Member
    23 Posts

    URL of older page versions Link to this post

    Hello everybody,

    I just found out, that if I change the URLSegment of a Page or even change the hierarchy SilverStripe has some mechanism to map the old URL(s) to the new URL(s). As this is a feature I've never heard of I just wanted to ask how reliable that one is respectively where to get more info about it.

    The reason why I'm asking is that I am in the process of restructuring our complete website. With approximately 2000 URL changes, correct redirection is a big issue. If SilverStripe can handle this that's fine with me. Otherwise I would have to develop such a feature by myself.

    Greetings,
    Rainer

  • inCharge
    Avatar
    Community Member
    102 Posts

    Re: URL of older page versions Link to this post

    Yes, it's reliable.

    If the URL doesn't exist, the version system is used to check whether a page with that URL used to exist but was renamed. If there are more than one with the same URL, the most recent is used.

    The code that does this is in ModelAsController::getNestedController

    I'm not sure if it works with nested URLs, but it'd only take you 5 minutes to check.

    421 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.