2019-02-23 16:49:38 +01:00
|
|
|
#index:
|
|
|
|
# path: /
|
|
|
|
# controller: App\Controller\DefaultController::index
|
2019-09-12 17:50:33 +02:00
|
|
|
|
|
|
|
# Redirect every url without an locale to the locale of the user/the global base locale
|
|
|
|
redirector:
|
|
|
|
path: /{url}
|
|
|
|
requirements:
|
|
|
|
url: ".*"
|
2019-09-12 21:41:38 +02:00
|
|
|
controller: App\Controller\RedirectController:addLocalePart
|
|
|
|
# Dont match localized routes (no redirection loop, if no root with that name exists)
|
2019-10-20 14:35:19 +02:00
|
|
|
condition: "not (request.getPathInfo() matches '/^\\\\/[a-z]{2}(_[A-Z]{2})?\\\\//')"
|