Details
-
Task
-
Status: New
-
Top
-
Resolution: Unresolved
-
None
-
None
-
None
-
5
-
Orion
-
BrXM Backlog
-
Undetermined
Description
TinyMCE post processes 'a' and 'img' html elements, removing or altering custom attributes that we use for the pickers. It does that in 2 occasions:
- On content insertion. That is, when you're working in a rich text field and have selected a document/image via the link/image pickers and you press ok
- On loading of the content (when opening the document for editing)
I've added 2 methods that reconfigure the cleaner:
enablePickerAnchorAttributes and enablePickerImgAttributes. They register our custom attributes for the 'a' and 'img' elements into tinymce's cleaner rules so they are preserved.
This tickets is about fixing 2 issues: # For the link picker we must set the attribute 'href' to the value 'http://'. But tinymce is changing this to 'http://localhost'
- When loading content, our re-confifguration hasn't occurred yet. Tinymce strips the 'a' and 'img' elements of their 'href' and 'src' attributes respectively; these are required attrs for the pickers to work.
Result is that we can pick a document/image and insert it in a rich text field, but after saving the document and reloading it they disappear.
Attachments
Issue Links
- relates to
-
CMS-15775 Investigate TinyMCE options for FE html cleaning
- New