[TYPO3] how to generate link

ries van Twisk typo3 at rvt.dds.nl
Wed Aug 1 16:32:27 CEST 2007


Hey,

I think Elmar instantiates cObject because it's more the OO way of  
doing things.

You are right about resources of course, although PHP is very  
efficient with
creating objects.

Ries


> Sorry for off topic, but I can't help myself.
>
>> http://t3flyers.wordpress.com/2007/08/01/using-the-typolink-function/
>
> why do you need to create always new tslib_cObject instance?
>
> $cObject = t3lib_div::makeInstance('tslib_cObject');
>
> I don't wonder that Typo3 consumes that much memory. Isn't it  
> better to
> use already created instance (the one from $GLOBALS['TSFE'])?
>
> The best would be to implement Sigleton pattern on some classes in
> makeInstance, but I don't see this happening. So at least, we  
> should use
> every available resource instead of creating new ones.
>
> -- 
> Jan Bednarik
> www.bednarik.org - web about Typo3 in czech
> _______________________________________________
> TYPO3-english mailing list
> TYPO3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english



More information about the TYPO3-english mailing list