|
| 1 | +.. include:: /Includes.rst.txt |
| 2 | + |
| 3 | +.. _tca: |
| 4 | + |
| 5 | +=============================== |
| 6 | +TCA (Table Configuration Array) |
| 7 | +=============================== |
| 8 | + |
| 9 | +In TYPO3, TCA stands for Table Configuration Array. It is a core part of the |
| 10 | +TYPO3 framework that defines how data is stored, displayed, and managed within |
| 11 | +the TYPO3 backend. TCA is essential for customizing and configuring how TYPO3 |
| 12 | +handles database tables and how content is presented in the backend interface. |
| 13 | + |
| 14 | +The TCA is essentially a large PHP array that |
| 15 | +defines the structure of database tables and their fields within TYPO3. |
| 16 | +It controls how data is displayed in forms, how records are listed, |
| 17 | +and how data validation and processing are handled. TCA is used to configure |
| 18 | +not only custom tables but also many of the core tables within TYPO3, |
| 19 | +like tt_content, which manages page content. |
| 20 | + |
| 21 | +.. _tca-what-is:: |
| 22 | + |
| 23 | +What is TCA used for? |
| 24 | +===================== |
| 25 | + |
| 26 | +TCA is used to: |
| 27 | + |
| 28 | +* TCA lets you define the fields of a database table, specifying data types, labels, default values, |
| 29 | + and constraints. You can configure various input types like text fields, checkboxes, and dropdowns. |
| 30 | +* TCA controls how forms are rendered in the TYPO3 backend. It defines the fields that are shown, their layout, |
| 31 | + and whether they are required or optional. |
| 32 | +* TCA allows developers to enforce validation rules on fields to ensure data integrity. For example, you can set a |
| 33 | + field to only accept numeric values or enforce a specific character limit. |
| 34 | +* TCA supports defining relationships between tables, such as one-to-one, one-to-many, and many-to-many relations. |
| 35 | + It manages how records from related tables are linked and displayed in the backend. |
| 36 | +* TCA, you can control which fields and records are editable, based on user roles and permissions. |
| 37 | +* Extend existing tables and create new ones with custom field definitions |
| 38 | + |
| 39 | +For example, when you create a new content element or extend an existing one, |
| 40 | +you define the fields using TCA in the Configuration/TCA directory of your extension. |
| 41 | +TYPO3 then uses this configuration to build the backend interface for editors. |
| 42 | + |
| 43 | +.. _tca-more-information: |
| 44 | + |
| 45 | +Where to find more information |
| 46 | +============================== |
| 47 | + |
| 48 | +To learn more about TCA and how to use it in your TYPO3 projects, you can refer to the official |
| 49 | +TYPO3 documentation: |
| 50 | + |
| 51 | +* :ref:`TYPO3 TCA Reference <t3tca:introduction>` |
| 52 | +* :ref:`Database records <t3coreapi:database-records>` |
| 53 | +* :doc:`Relations <t3coreapi:ExtensionArchitecture/Extbase/Reference/Domain/Model#relations>` |
0 commit comments