[TYPO3-core] RFC #7753: EM warns No XCLASS inclusion code found if you use $GLOBALS['TYPO3_CONF_VARS']

Franz Holzinger franz at ttproducts.de
Thu May 20 07:54:41 CEST 2010


Hello,

Le 14/05/2010 16:01, Christian Kuhn a écrit :
> Hey,
> 
> Franz Holzinger wrote:
>> Branch: 4.2,4.3,trunk
> 
> 4.3, trunk
> 
>> Problem:
>> The EM always gives a red lined error message if you use
>> $GLOBALS['TYPO3_CONF_VARS'] instead of $TYPO3_CONF_VARS. This makes many
>> users think that this is a bug inside of the extension. So many of them
>> will continue to send emails to the extension authors, if you do not fix
>> this in TYPO3. This is very annoying to extension developers!
>> Wrong file names and paths used in the EM should be reported. Do not
>> keep quiet in the EM!

> Thanks, this XCLASS definition test nagged me for quite some time, too.
> 
> +1 on reading and testing with the following changes (attached):
> 
> - Removed hunk 1 and 2: Should be a separate RFC, I personally don't
> throw a debug message if no ext_emconf.php file is found in a directory.
Then I will generate a separate RFC for that.

> - Hunk 3: Removed the check "a filename containing 'div' does not need
> to have a XCLASS". Technically, possible reasons for a missing xclass
> definition are either if the class is a xclass itself, or if the class
> is defined as final. I don't think we should add some additional
> arbitrary namespace convention here.
I urgently need the possibility to get rid of the XCLASS warnings with a
class of library functions. When you call it with the class name and do
not generate an object, then you cannot use XCLASS. Therefore the error
message in the EM is completely wrong in this case.
So I propose to use the naming '_div' inside of a class name to be for
static classes. See the class t3lib_div which also has a 'div' inside of
its class name.

> - Removed hunk 4: Not related to this RFC.
Then I will generate a separate RFC for that.

- Franz



More information about the TYPO3-team-core mailing list