Skip to content
Snippets Groups Projects
Commit 4bd962b5 authored by Juan Manuel Vergés Solanas's avatar Juan Manuel Vergés Solanas
Browse files

[BUGFIX] Fix for multiple TinyMCE in same page. Avoids multiple initialization...

[BUGFIX] Fix for multiple TinyMCE in same page. Avoids multiple initialization which was breaking the save in TYPO3.
parent 9f8c1340
No related branches found
No related tags found
1 merge request!6[BUGFIX] Fix for multiple TinyMCE in same page.
......@@ -299,11 +299,16 @@ class Loader {
$configuration .= '
var $ = jQuery = window.TYPO3.jQuery;
var RTEarea = RTEarea || window.RTEarea;
define([\'TYPO3/CMS/Tinymce/../../../../typo3conf/ext/tinymce/tinymce_node_modules/tinymce/jquery.tinymce.min.js\'], function () {
$(\'.tinymce4_rte\').tinymce({
script_url : \'' . $this->getPath($tinymceSource, TRUE) . '\',
' . $this->replaceTypo3Paths($this->tinymceConfiguration['configurationData']) . '
});
if(!$(\'.tinymce4_rte\').data(\'first\')){
$(\'.tinymce4_rte\').data(\'first\', true);
$(\'.tinymce4_rte\').tinymce({
script_url : \'' . $this->getPath($tinymceSource, TRUE) . '\',
' . $this->replaceTypo3Paths($this->tinymceConfiguration['configurationData']) . '
});
}
});
';
$configuration .= $this->tinymceConfiguration['postJS'];
......@@ -410,4 +415,4 @@ class Loader {
}
}
?>
\ No newline at end of file
?>
  • Marco Huber @mhuber84

    mentioned in merge request !7 (merged)

    ·

    mentioned in merge request !7 (merged)

    Toggle commit list
  • Contributor

    Because of this patch the RTE is loaded only in the first inline element. I created a new merge request which should handle both.

  • Stefan Galinski :video_game: @sgalinski

    mentioned in commit 55451595

    ·

    mentioned in commit 55451595

    Toggle commit list
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment