[TYPO3-UG Freiburg] TYPO3 7.6: Description-Eingabefeld beim Seitentyp Shortcut aktivieren
Ben Robinson
robinson2.ben at gmail.com
Fri Aug 5 12:14:05 CEST 2016
Hallo Nico,
danke!
Ich habe das gerade mal gestestet und es hat funktioniert. Es hat den kleinen Nachteil, dass es alles hart überschreibt; also wenn eine nachträglich installierte Extension das TCA an dieser Stelle ändern würde, oder sich das TCA bei einem TYPO3-Update ändern würde, dann würde diese Änderung nicht greifen, da sie ja mittels $GLOBALS['TCA']['pages']['types']['4']['showitem'] in typo3conf/extTables.php überschrieben wird. Daher habe ich noch etwas recherchiert, ausprobiert und noch eine andere Lösung gefunden, die die bestehende Konfiguration ergänzt, statt zu überschreiben:
typo3conf/extTables.php
<?php
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes(
'pages', // Table name
'--palette--;LLL:EXT:frontend/Resources/Private/Language/locallang_tca.xlf:pages.palettes.metatags;metatags', // Field list to add
'4', // List of specific types to add the field list to. (If empty, all type entries are affected)
'after:abstract' // Insert fields before (default) or after one, or replace a field
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addToAllTCAtypes(
'pages_language_overlay',
'--palette--;LLL:EXT:frontend/Resources/Private/Language/locallang_tca.xlf:pages.palettes.metatags;metatags',
'4',
'after:abstract'
);
Viele Grüße
Ben
> Am 04.08.2016 um 22:27 schrieb Nico de Haen <typo3 at ndh-websolutions.de>:
>
> Du wird unter $GLOBALS['TCA']['pages']['types']['4']['showitem'] definiert.
>
> Standardmäßig steht da:
>
> --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.shortcut;shortcut, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.shortcutpage;shortcutpage, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.title;title, tx_realurl_pathsegment;;137;;, tx_realurl_exclude, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.access, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.visibility;visibility, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.access;access, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.metadata, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.abstract;abstract, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.editorial;editorial, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.appearance, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.layout;layout, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.behaviour, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.links;links, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.language;language, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.miscellaneous;miscellaneous, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.resources, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.media;media, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.storage;storage, --palette--;LLL:EXT:cms/locallang_tca.xlf:pages.palettes.config;config, --div--;LLL:EXT:cms/locallang_tca.xlf:pages.tabs.extended, --div--;LLL:EXT:lang/locallang_tca.xlf:sys_category.tabs.category, categories, tx_browserpagetitle_browser_title;;;;1-1-1
>
> da muss dann noch
>
> description;LLL:EXT:cms/locallang_tca.xlf:pages.description_formlabel
>
> rein. Z.B. nach dem title.
>
> Gruß,
>
> Nico
>
>
> Am 04.08.16 um 16:17 schrieb Ben Robinson:
>> Hallo zusammen,
>>
>> hat jemand eine Idee, wie ich das Description-Eingabefeld beim Seitentyp Shortcut aktivieren kann?
>> Es wird automatisch ausgeblendet, sobald ich den Seitentyp auf "Shortcut" umstelle.
>> Klar, normalerweise braucht man bei Shortcuts auch keine Description – ich in diesem Fall aber schon, da ich die Infos aus der Description bei speziellen Menüs-der-Unterseiten ausgebe.
>>
>> Ich schätze mal es muss über $GLOBALS['PAGES_TYPES'] in extTables.php oder AdditionalConfiguration.php ins TCA, aber wie genau?
>>
>> Beste Grüße
>> Ben
>> _______________________________________________
>> TYPO3-UG-Freiburg mailing list
>> TYPO3-UG-Freiburg at lists.typo3.org
>> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-ug-freiburg
> _______________________________________________
> TYPO3-UG-Freiburg mailing list
> TYPO3-UG-Freiburg at lists.typo3.org
> http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-ug-freiburg
More information about the TYPO3-UG-Freiburg
mailing list