[Typo3-dev] $TCA / $tables.php inconsistency

Christopher bedlamhotel at gmail.com
Mon Aug 8 05:03:07 CEST 2005


Hello list,

I'm working on an extension that makes use of fe_adminLib.inc, I'm
trying to make use of the 'fe_userOwnSelf' property so that the
created records' fe_cruser_id' field will be stamped with the user's
uid [1] - so far, so good.

For one type of records, this works completely as intended, but for a
second type, it does not work at all - records' fe_cruser_id fields
remain empty, even though the record *does* get correctly created. The
wording in the TSref points to the 'ctrl' section of the $TCA array as
the likely source of the problem. As far as I can tell, the relevant
parts of tca.php for each table are identical. Each one's 'ctrl'
section contains the following:

"ctrl" => $TCA["tx_relevant_table_name"]["ctrl"]

...which, I assume, is calling on the contents of the 'ctrl' section
of the $TCA as configured in tables.php, which contains the following
(identical) code for each table:

$TCA["tx_relevant_table_name"] = Array (
	"ctrl" => Array (
		"title" => "LLL:EXT:ext_key/locallang_db.php:tx_relevant_table_name",
		"label" => "title",
		"tstamp" => "tstamp",
		"crdate" => "crdate",
		"cruser_id" => "cruser_id",
		"fe_cruser_id" => "fe_cruser_id",
		...etc...

I was able to confirm that 'fe_cruser_id' is NOT present in the second
table's portion of the $TCA using the BE's $TCA viewer (Tools >
Configuration > $TCA), but  I'm a bit stuck about how to debug the
problem further. As mentioned, the setup is 100% functional, *except*
for this one problem where the 'fe_userOwnSelf' proprerty is not
honoured due to the $TCA problem.

Can anyone suggest how to proceed in the debugging process or what I
might have overlooked?


-Christopher

[1] http://typo3.org/documentation/document-library/doc_core_tsref/fe_adminLib_inc/




More information about the TYPO3-dev mailing list