[TYPO3-dev] Quick PHP question

Oliver Salzburg oliver.salzburg at googlemail.com
Wed Mar 14 14:14:39 CET 2012


On 2012-03-14 14:00, Jigal van Hemert wrote:
> Hi,
> 
> On 14-3-2012 13:43, Oliver Salzburg wrote:
>> The statement "only one extension of a PHP class can exist at a time"
>> is really confusing me.
>> Was that true at some point in time or did I just skip some important
>> pages in my PHP lecture?
> 
> No, it's the way XCLASSes are implemented. There is one item available
> in the global configuration array to define which script contains the
> extended version of the class.
> 
> This is done because the XCLASSing needs to happen transparently to the
> code which creates the object:
> $localCObj = t3lib_div::makeInstance('tslib_cObj');
> 
> This might result in an object of class ux_tslib_cObj if an extension
> defined an XCLASS of tslib_cObj.
> 

Am I assuming correctly that XCLASS is something specific to TYPO3?
Because sometimes it sounds like it would be a PHP feature, but I've
never heard of it.




More information about the TYPO3-dev mailing list