TYPO3 - markhowellsmead/helpers GitHub Wiki
Ajax
Command Line Interface (CLI)
Content element start and end time
TYPO3 6.2 (and perhaps 7?) don't usually allow you to set a start or end time for a content element in a language other than sys_language_uid=0
. To get around this, add the following lines to the ext_tables.php file of the template extension.
unset($GLOBALS['TCA']['tt_content']['columns']['starttime']['l10n_display']);
unset($GLOBALS['TCA']['tt_content']['columns']['starttime']['l10n_mode']);
unset($GLOBALS['TCA']['tt_content']['columns']['endtime']['l10n_display']);
unset($GLOBALS['TCA']['tt_content']['columns']['endtime']['l10n_mode']);
Content Element Wizard
Adds a plugin directly to the content element wizard, instead of requiring the editor to choose “General plugin” and then the specific plugin.
- Add the following code to TSConfig.
Form
relates to the plugin name. (Fluid template.)
mod.wizards.newContentElement.wizardItems.plugins {
elements {
my_extension {
icon = ../typo3conf/ext/my_extension/Resources/Public/Icons/Form.gif
title = LLL:EXT:frp_browsercheck/Resources/Private/Language/locallang_be.xlf:my_extension_form.title
description = LLL:EXT:my_extension/Resources/Private/Language/locallang_be.xlf:my_extension_form.description
tt_content_defValues {
CType = list
list_type = my_extension_form
}
}
}
}
ExtBase
Localization/Translation
namespace Frappant\FrpBrowsercheck\Controller;
use TYPO3\CMS\Extbase\Utility\LocalizationUtility;
…
echo LocalizationUtility::translate('mailsubject', 'FrpBrowsercheck');
var_dump
\TYPO3\CMS\Extbase\Utility\DebuggerUtility::var_dump($var);