[TYPO3-ect] mergeExtendingTCAs
    Franz Holzinger 
    franz at fholzinger.com
       
    Wed Sep  6 09:22:39 CEST 2006
    
    
  
Hello Elmar,
> I hope I understand the problem. Here comes the information you demand:
> 
>     tx_div::loadTcaAdditions($ext_keys);
> 
/* loadTcaAdditions($ext_keys)
*
* Your extension may depend on fields that are added by other
* extensios. For reasons of performance parts of the TCA are only
* loaded on demand. To ensure that the extended TCA is loaded for
* the extensions you depend on or which extend your extension by
* hooks, you shall apply this function.
*
* @param array     extension keys which have TCA additions to load
*/
function loadTcaAdditions($ext_keys){
	global $_EXTKEY, $TCA;
	
	//Merge all ext_keys
	if (is_array($ext_keys)) {
	for($i = 0; $i < sizeof($ext_keys); $i++){
		//Include the ext_table
		$_EXTKEY = $ext_keys[$i]; // added by F.Rakow
		include(t3lib_extMgm::extPath($ext_keys[$i]).'ext_tables.php');
	}
	}
}
But the extension authors must add there extensions to this list by 
themselves:
ext_localconf.php:
if (!defined ('STATIC_INFO_TABLES_EXTkey')) {
	define('STATIC_INFO_TABLES_EXTkey','static_info_tables');
}
$GLOBALS['TYPO3_CONF_VARS']['EXTCONF'][STATIC_INFO_TABLES_EXTkey]['extendingTCA'][] 
= $_EXTKEY;
I think we should make this array key name 'extendingTCA' common for all 
extensions. Where should this be documented?
- Franz
    
    
More information about the TYPO3-team-extension-coordination
mailing list