[TYPO3-ect] ECT library
Elmar Hinz
elmar.DOT.hinz at team.MINUS.red.DOT.net
Wed Mar 8 18:49:22 CET 2006
Stanislas Rolland schrieb:
> Perhaps methods to access Static Info Tables: countries, regions,
> languages, taxes? Would it be the right place for this?
>
> Stanislas
>
Hi Stanislas,
it's a good question if it the right place. $GLOBALS['LANG'] and
$GLOBALS['DB_LAYER'] are well done singletons that don't need to be
duplicated in the ECT library. I would assume that this localization
parameters belong into a simlilar global singleton. Either as one
object or several ones. $GLOBALS['LOCALS'] ?
Already queried information would be available in the singleton for
duration of the request and repeated queries for the same informations
would be prevented.
Which methods would be necessary to access the information? I guess
you have a lot of experience with it.
Regards
Elmar
P.S.
I don't really like the direct access to the global variables. I would
prefer a call like this:
$langPointer =& t3lib_div::findLANG(); instad of $GLOBALS['LANG'].
That would give flexibility behind the getLANG() factory method.
More information about the TYPO3-team-extension-coordination
mailing list