[TYPO3-ect] recursive pid function for tx_div
Christian Welzel
gawain at camlann.de
Mon Aug 13 16:35:35 CEST 2007
Steve Ryan wrote:
> static function findCObjectSingleton() {
> if(!is_object(self::$cObj)) {
> self::$cObj=t3lib_div::makeInstance('tslib_cObj');
> debug(array('creating cobj'));
> }
> debug(array('returning cobj'));
> return self::$cObj;
> }
Would be nicer to have something like this:
static function findCObjectSingleton($data = NULL, $table = '') {
if(!is_object(self::$cObj)) {
self::$cObj=t3lib_div::makeInstance('tslib_cObj');
debug(array('creating cobj'));
}
debug(array('returning cobj'));
if(is_array($data))
self::$cObj->start($data, $table)
return self::$cObj;
}
--
MfG, Christian Welzel
GPG-Key: http://www.camlann.de/key.asc
Fingerprint: 4F50 19BF 3346 36A6 CFA9 DBDC C268 6D24 70A1 AD15
More information about the TYPO3-team-extension-coordination
mailing list