From ac95bc0ea0015ffee6a676470d5e244ed96d0b6b Mon Sep 17 00:00:00 2001 From: Torsten Oppermann <torsten@sgalinski.de> Date: Tue, 18 Sep 2018 15:03:38 +0200 Subject: [PATCH] [TASK] Update readme, removing whitespace in code samples of deprecation warnings --- Classes/Controller/MailController.php | 2 +- README.md | 13 ++++++------- 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/Classes/Controller/MailController.php b/Classes/Controller/MailController.php index bef75ffc..f5e1169a 100644 --- a/Classes/Controller/MailController.php +++ b/Classes/Controller/MailController.php @@ -381,7 +381,7 @@ class MailController extends ActionController { } // provide code example on how to register correctly - $code = '$GLOBALS[\'sgmail\'][\'' . $extensionName . '\'][\' ' + $code = '$GLOBALS[\'sgmail\'][\'' . $extensionName . '\'][\'' . \str_replace('.php', '', $configFile) . '\'] = \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath(\'' . $extensionName . '\') . \'/Configuration/SgMail/' . $configFile . '\';'; diff --git a/README.md b/README.md index d405cbed..89d2f985 100644 --- a/README.md +++ b/README.md @@ -23,8 +23,12 @@ sg_mail ist multi-site and multi-language ready. ### Registering your Extension To register your extension with sg_mail, you need a **Configuration File** for each template you want to integrate. -It needs be a *.php* file and has to be inside the Configuration folder **typo3conf/ext/{your_extension}/Configuration** of your extension. -The naming of the file should be in upper camel case, matching your template name. +It needs be a *.php* file and has to be inside the Configuration folder **typo3conf/ext/{your_extension}/Configuration/Sgmail** of your extension. + +Additionally you need to make your registration file known in your **ext_local_conf.php** file: + + // register mail templates + $GLOBALS['sgmail']['my_extension_key']['unique_template_name'] = \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath('my_extension_key') . '/Configuration/SgMail/MyTemplate.php'; sg_mail will automatically parse valid configuration files of all extensions within your TYPO3 instance. @@ -159,11 +163,6 @@ This happens also if the given iso code of the language is not known (inside the In your template editor you have automatically all languages of your page shown. -## Using sg_mail with Formhandler - -In your **setup.txt** of your formhandler extension, you have to invoke the **FormhandlerFinisherService** of sg_mail. -This is done in a similar fashion as with the usual finisher classes. - ### Example finishers { -- GitLab