Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

General Questions /

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

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

How to set a custom URL route to lowest priority?

Go to End

2 Posts   1056 Views


Community Member, 33 Posts

19 November 2012 at 7:33pm

Edited: 20/11/2012 3:16am

I am trying to implement clean urls with an variable at the top level (without having a controller action in the URL)
ex. instead of having just

The route below works, but it triggers before everything else. How can I specify my custom route to be the last one that is being checked (lowest priority even after the SiteTree)?

Name: approutes
 - 'framework/routes#rootroutes'
 - 'framework/routes#coreroutes'
 - 'framework/routes#modelascontrollerroutes'
    '$MyVar': 'AppController'


Community Member, 33 Posts

20 November 2012 at 11:12am

Is a custom handleRequest() override my only option? Anyone?