[TYPO3-50-general] Need help with Routing
Karsten Dambekalns
karsten at typo3.org
Mon Mar 2 20:49:09 CET 2009
Hi (?:.*)
On 02.03.2009 18:22 Uhr, Robert Lemke wrote:
> I agree - how can we solve this?
Bastian and I talked about routing for some hours last Friday. We had
this idea to solve this (Bastian, if I miss something, feel free to fill
in):
* Packages can define "Sub"-Routes in their Routes.yaml
* TYPO3 by default only reads Routes.yaml from the global configuration
space (and context, of course)
* "Sub"-Routes can be imported/mounted under a prefix in the global
configuration
* the later could also be done through some tool, preferably the package
manager, which could also alert the user of existing "sub"-routes (or
presets as you might call them)
* a routing setup tool will allow for display and simulated matching of
URIs against the configuration to ease debugging and setup
The syntax with which the "sub"-routes will be like this:
---- YAML ----
uriPattern: tools/{TYPO3CR}'
routeParts:
TYPO3CR:
subRoutes:
package: TYPO3CR
uriPattern: tools/{backupThingie}'
routeParts:
backupThingie:
subRoutes:
package: SiteBackup
file: OptimizedRoutes.yaml
---- YAML ----
This means that "sub"-routes can be "mounted" with any prefix and will
be configured like a route part. If only 'package' is given, Routes.yaml
will be used, if 'file' is given a specific set of rules can be imported
(this can be given multiple times to allow for modular rulesets, they
are then combined).
'file' can not hold a path and is always relative to the package's
'Configuration' directory.
Notes:
* the naming of the "sub"-routes needs to be finalized :)
* if you have ideas to share, shoot!
* I added this to http://forge.typo3.org/issues/show/2126 - feel free to
comment there
Regards,
Karsten
More information about the TYPO3-project-5_0-general
mailing list