I'm adding new content types to my TYPO3 and I want to use FlexForms to define each content type options form.
I have followed this example: https://docs.typo3.org/typo3cms/extensions/fluid_styled_content/latest/AddingYourOwnContentElements/
And modified it to use FlexForms from this example: https://wiki.typo3.org/Extension_Development,_using_Flexforms
But I believe I don't quite understand the settings in Configuration/TCA/Overrrides/tt_contant.php
:
// Adds content new content elements
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPlugin(
[
'LLL:EXT:lu_content/Resources/Private/Language/locallang.xlf:contacts.title',
'lu_content__contacts',
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extRelPath('lu_content').'Resources/Public/Icons/Contacts.svg',
],
'CType',
'lu_content'
);
$GLOBALS['TCA']['tt_content']['types']['lu_content__contacts']['showitem'] = 'CType;;;1-1-1,pi_flexform;;;1-1-1';
$GLOBALS['TCA']['tt_content']['columns']['pi_flexform']['config']['ds'][',lu_content__contacts'] = 'FILE:EXT:lu_content/Configuration/FlexForms/Contacts.xml';
The form works, but looks like this:
How do I get the form not to fall under Plugin Options?
And how do I make the title/header to be used in to list view? Currently i get [notitle] after save in the content list.
Thank you in advance.
PS: I'm currently developing on TYPO3 v7 but with support for v8.
The Text for the tab as well as the arrangement of any tabs and fields is defined for general plugins in
If you have defined an own CType it's quite probable that you wish to define own fields, palettes and types, hide standard-fields and perhaps replace default labels. The whole configuration for tt_content is quite complicated as it is used for all different content-elements and it can be seen in backend below
System -> Configuration -> GLOBALS[TCA]
:The simplest option is to replace the label for the tab in
$GLOBALS['TCA']['tt_content']['types']['list']
.Before / Default:
After / location to fill with own label: (look for
###YOUR_LABEL###
):and a more difficult approach would be to define an own type in
$GLOBALS['TCA']['tt_content']['types']
.Here you find The documentation about TCA.
For your case are especially interesting the following chapters:
But if you want to change labels or other configuration of single fields you'd had to refer to the chapter / configuration about columns.
In the area ctrl you still can define some general options like sorting-fields or the behavior when the whole element is copied, have a look in that chapter to get an impression about all options. Also the desired and default label and value-field is configured there with
its also possible to combine two or more fields for the default display:
you might still want to add the option
Configuring the form for a plugin can take quite some time even to understand all the options, but in general there are very much options to individualize it related to many needs. It's even possible to define user-functions to handle and display own options in the form which are not covered by the existing options.