[TYPO3-mvc] controller and unique id

Steffen Ritter info at rs-websystems.de
Mon Jul 20 10:53:50 CEST 2009


Bastian Waidelich schrieb:
>> when inserting more than one plugin on one page there is the need of 
>> an unique identifier.
> 
> Good, that you bring up this topic. The prefixing is not yet elaborate 
> in fluid & extbase (neither in FLOW3).
> 
> 
>> the controller could create an own with uniqid()
> 
> The problem is, that sometimes you want to share the _same_ namespace 
> across multiple controllers. And you wouldn't want to use the tt_content 
> uid by default as the details view might be on a different page...
> 
> So I think, we need a more flexible approach here.

Why don't we say mycontroller[var] is the overall context.
additionally we allow to define other contexts in controller

like
additionalContexts => array(
	'sv' => 'action1,action2,action6',
	'latest' => 'action5',
)

mycontroller_sv[myvar] would only be applied in action 1,2 and 6
mycontroller_latest[mycar] only passed to action5

and in addition we could provide an generic build in content 
rid{field:uid} which applies only to current plugin record

regards

STeffen


More information about the TYPO3-project-typo3v4mvc mailing list