[TYPO3-ect] lib/div: some common initialization before any action

Ernesto Baschny [cron IT] ernst at cron-it.de
Mon Mar 26 13:40:58 CEST 2007


Elmar HInz wrote: on 26.03.2007 12:34:

>> Elmar, the problem with the full "object orientation" is not possible
>> with "t3lib_div::makeInstance", since you cannot pass the newly created
>> object any parameters. This is why you sometimes need some kind of
> 
> For parameters there is makeInstanceClassName:
> 
> $className = tx_div::makeInstanceClassName('tx_xxxx');
> 
> $object = new $className($many, $lucky, $parameters);
> 
> see also:
> 
> t3lib_div::makeInstanceClassName

Cool, I never though of that, thanks for the tip! :)

Why not use that when instanciating the controller and passing it the
$parameters and $configuration so that the contructor can make use of it?

Cheers,
Ernesto


More information about the TYPO3-team-extension-coordination mailing list