[TYPO3-dev] Making TCA field in existing tab

François Suter fsu-lists at cobweb.ch
Fri Aug 5 11:14:34 CEST 2011


Hi,

> Creating TCA field makes it in a new tab "Extended" in the backend.
> How to create it in already existing tab, let's say "Access"?

Look at method t3lib_extMgm::addFieldsToPalette().

Here's some code taken from a personal customization:

	// Add a "no print" and "collapsible" checkboxes to tt_content
$tempColumns = array(
	'tx_customconfig_noprint' => array (
		'exclude' => 0,
		'label' => 
'LLL:EXT:custom_config/locallang_db.xml:tt_content.tx_customconfig_noprint',
		'config' => array (
			'type' => 'check',
		)
	),
	'tx_customconfig_collapsible' => array (
		'exclude' => 0,
		'label' => 
'LLL:EXT:custom_config/locallang_db.xml:tt_content.tx_customconfig_collapsible',
		'config' => array (
			'type' => 'check',
		)
	),
	'tx_customconfig_collapsed' => array (
		'exclude' => 0,
		'label' => 
'LLL:EXT:custom_config/locallang_db.xml:tt_content.tx_customconfig_collapsed',
		'config' => array (
			'type' => 'check',
		)
	)
);
t3lib_extMgm::addTCAcolumns('tt_content', $tempColumns, 1);
t3lib_extMgm::addFieldsToPalette('tt_content', 'frames', 
'--linebreak--,tx_customconfig_noprint,tx_customconfig_collapsible,tx_customconfig_collapsed', 
'after:section_frame');

HTH

-- 

Francois Suter
Cobweb Development Sarl - http://www.cobweb.ch




More information about the TYPO3-dev mailing list