[TYPO3-team-core-v5] TYPO3 v5 Routing

Bastian Waidelich waidelich at network-publishing.de
Mon Jun 16 19:08:31 CEST 2008


Ernesto Baschny [cron IT] wrote:

Hi Ernesto,

> Do we then have GET-parameters like:
> F3_TYPO3_CMS[controller]=page&F3_TYPO3_CMS[action]=show&F3_TYPO3_CMS[id]=33& 

Yes, probably.
At first I thought we could skip this step. But the array-syntax for GET 
parameters is very powerful. Besides it's the only way I can think of to 
get a namespace-like functionality into forms.
Nevertheless, I guess a set of default routes will be distributed with 
the TYPO3 package. Plugin sub routes could default to s.th. like 
"[controller]/[action]/key1/value1...".
Even an integration into FLOW3's argument management is thinkable. So 
you would add an argument to your  controller in the init function:
	$this->arguments->addNewArgument('myArg1');
	$this->arguments->addNewArgument('myArg2');
and *tada* a default sub route 
"myPlugin/[action]/myArg1/myVal1/myArg2/myVal2" is available.


> Also missing and interesting would be to know that the mechanism will 
> also work from the CLI and other ways of interacting with TYPO3 (SOAP, 
> etc). So that we could do stuff like e.g.

I might err, but for the CLI you probably don't need routing 
functionality as you're calling controller-actions directly.


>   php cli.php -controller=cache -action=clear -page=33

This works already (not the cache clearing, but the CLI command pattern):
php index.php myController myAction myParameters...

Clean SOAP URLs and RESTful web services would be possible with the 
concept. Based on dynamic parts in the URL or some request headers a 
context switch could take place. But that's science fiction for now ;)


> Is the concept written down somewhere as a whole, or is it still a 
> work-in-progress?

Right now it's just a bunch of abstract ideas. As soon as the whole 
concept is a bit more concrete, I'll write it down!


> I think many examples would ease the understanding of the concept, with 
> comparisions between now (realurl) and then (FLOW3). That would also 
> allow easily to recognize problems beforehand.

Yes, that's true. I'm already investigating URLs of professional 
websites to collect data for examples and tests.

Thanks for your input!
Bastian


More information about the TYPO3-team-core-v5 mailing list