-
Bug
-
Resolution: Unresolved
-
Minor
-
None
-
4.3.5
-
MOODLE_403_STABLE
tinyMCE strips the multi language tag if paragraph tags are used inside span tag. This breaks multilanguage filter functionality.
Reproduction steps:
- go to profile -> preferences -> editor preferences -> tinyMCE Editor -> save changes
- got to a test course or similar, create a new activity "Quiz"
- add a new question "description"
- set question name to "test"
- under "question text" in tinyMCE editor got to "view" -> "source code"
- add code
<span lang="en" class="multilang"> |
<p>English text 1</p> |
</span>
|
<span lang="de" class="multilang"> |
<p>German text 1</p> |
</span>
|
<p>break</p> |
<span lang="en" class="multilang"> |
<p>English text 2</p> |
</span>
|
<span lang="de" class="multilang"> |
<p>German text 2</p> |
</span>
|
- click "save"
- open "view" -> "source code"
- code has been stripped to
<p>English text 1</p> |
<p></p>
|
<p>German text 1</p> |
<p>break</p> |
<p>English text 2</p> |
<p></p>
|
<p>German text 2</p> |
Note: it works if paragraph tags are not used inside the spant tag:
<p><span class="multilang" lang="en"> English text 1 </span> <span |
class="multilang" lang="de"> German text 1 </span></p> |
<p>break</p> |
<p><span class="multilang" lang="en"> English text 2 </span> <span |
class="multilang" lang="de"> German text 2 </span></p> |
See also: https://github.com/tinymce/tinymce/issues/9720
TinyMCE Version: 2023100900