score:3

Accepted answer

Each route must be defined separately. And don't use the same identifier, otherwise you'll override the first route definition.

myFirstRoute:
    pattern: /
    defaults: { _controller: airpaprFramesWebsiteBundle:Intro:index }
myDuplicateRoute:
    pattern: /intro
    defaults: { _controller: airpaprFramesWebsiteBundle:Intro:index }

This may also help > symfony2 use multiple url pattern for a single Controller Action using regular expression

Next time, try to use app/console router:debugcommand line to check your routes definition and figure out what's going wrong.


Related Query

More Query from same tag