Skip to content

Instantly share code, notes, and snippets.

@manuelselbach
Last active January 29, 2021 08:49
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save manuelselbach/1597680145f846bef3a2 to your computer and use it in GitHub Desktop.
Save manuelselbach/1597680145f846bef3a2 to your computer and use it in GitHub Desktop.
Register Plugin in new Element Wizard made simple! The file "ContentElementWizard.txt" should be located under "[extension_key]/Configuration/TSconfig/ContentElementWizard.txt" for this example. All the TYPO3 standard plugin registration stuff has also to be done. Have fun!
mod.wizards.newContentElement.wizardItems.plugins {
elements {
[extension_key] {
icon = ../typo3conf/ext/[extension_key]/Resources/Public/Icons/icon.png
title = LLL:EXT:[extension_key]/Resources/Private/Language/locallang_be.xlf:plugin_title
description = LLL:EXT:[extension_key]/Resources/Private/Language/locallang_be.xlf:plugin_description
tt_content_defValues {
CType = list
list_type = [extensionkey]_[pluginname]
}
}
}
}
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPageTSConfig('<INCLUDE_TYPOSCRIPT: source="FILE:EXT:[extension_key]/Configuration/TSconfig/ContentElementWizard.txt">');
@sypets
Copy link

sypets commented Jan 29, 2021

A Google search brought me to this page.
Please add which TYPO3 version this is for or keep it updated. The above example is outdated:

  1. <INCLUDE should be replaced by @import, e.g. "@import 'EXT:myextension/Configuration/TSconfig/Page/Wizards/NewContentElement.tsconfig'"
  2. TSconfig file endings should be .tsconfig and not .txt
  3. mod.wizards.newContentElement.wizardItems.plugins.elements.myextension.icon is deprecated, should be iconIdentifier

Also, this is documented in the official documentation:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment