[Typo3] How to extend tbl_cms for loadTCA('fe_users')

Christian Stuedemann typo3 at christian-stuedemann.de
Mon Feb 21 19:39:39 CET 2005


Dear Alex,

that's all done already and the new fields show up in the BE TCA
configuration, but I can't access them in a FE-extension that reads TCA
by calling t3lib_div::loadTCA('fe_users'). The FE-extension knows only
the values that are set in tbl_cms.php.
Check function mergeExtendingTCAs in cwt_feedit which tries to solve
this problem by scanning a list of extensions. That solution has got the
disadvantage, that the class has to know the realted extensions to scan.
I am searching for a solution that uses loadTCA(...) only.

Best regards,
Christian

Am Mon, 2005-02-21 um 12.14 schrieb media.res | alex widschwendter:
> hi christian,
> 
> > I've made a BE-extension 'csextfeadr' that extends the fe_users table by
> > some additional columns. That works fine. Now I'm using
> > t3lib_div::loadTCA('fe_users') to read the column's configuration in a
> > frontend extension. I get all configs of the standard columns noted in
> > typo3/sysext/cms/tbl_cms.php, but I don't get the additional columns,
> > because they're not part of the tbl_cms.php file.
> > How can I extend the content of tbl_cms.php without touching the
> > original file so that loadTCA('fe_users') gets all the data?!
> 
> have you started your extension with the kickstarter? if yes, you should 
> have something similar to
> 
> <snip>
> $tempColumns = Array (
> 	"firstname" => Array (		
> 		"exclude" => 1,		
> 		"label" => 
> "LLL:EXT:mr_linklist/locallang_tca.php:mr_linklist.firstname",		
> 		"config" => Array (
> 				"type" => "input",	
> 				"size" => "30",	
> 			)
> 	),
> );
> 
> 
> t3lib_div::loadTCA("fe_users");
> t3lib_extMgm::addTCAcolumns("fe_users",$tempColumns,1);
> </snip>
> 
> in the ext-tables file of your extension? and it should work.
> 
> hth alex
> _______________________________________________
> Typo3-english mailing list
> Typo3-english at lists.netfielders.de
> http://lists.netfielders.de/cgi-bin/mailman/listinfo/typo3-english




More information about the TYPO3-english mailing list