Hi,
i need to modify the structure of the plugin format of a rte. Is it possible to change the tag B to the tag STRONG?
Thanks
Solved! Go to Solution.
Views
Replies
Total Likes
Hi
The Approach that you would need to achieve this is Overlay.
The approach of copying the relevant js, /libs/cq/ui/rte/core/commands/DefaultFormatting.js and adding it under the apps content folder, /apps/cq/ui/rte/core/commands/DefaultFormatting.js I then amended the copy of DefaultFormatting.js copied under apps. AEM then seems to use the 'overlay' technique to apply the strong tag.
Look at this Stackoverflow link :- http://stackoverflow.com/questions/17946117/strong-tag-getting-replaced-to-b-tag-in-cq5
//
you can update the map with an identity mapping (i.e. map b
tags to b
tags) so that nothing gets changed.
Add an htmlRules
node like the following to your dialog.xml (as a sibling of the rtePlugins
node):
...<rtePlugins jcr:primaryType="nt:unstructured">...<misctoolsjcr:primaryType="nt:unstructured"features="sourceedit"/></rtePlugins><htmlRules jcr:primaryType="nt:unstructured"><docType jcr:primaryType="nt:unstructured"><typeConfig jcr:primaryType="nt:unstructured"><semanticMarkupMap jcr:primaryType="nt:unstructured"b="b"i="i"/></typeConfig></docType></htmlRules>... ...
or you can add nodes directly to your dialog in CRXDE Lite if you're not using maven or something similar (this screenshot shows the default, unmodified <i>
to <em>
mapping -- don't forget to change that if that's not what you want):
And to understand Overlay example :- http://experience-aem.blogspot.in/2014/02/aem-cq-56-extend-richtext-editor-add-new-plugin-pullquote....
I hope this would help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes
Hi Samuel,
Take a look at previous thread discussing same:
Views
Replies
Total Likes
Yes, it is. But you have to develop a custom plugin for that. And use it in RTE.
https://docs.adobe.com/docs/en/aem/6-1/administer/operations/page-authoring/rich-text-editor.html
--
jitendra
Views
Replies
Total Likes
Hi
The Approach that you would need to achieve this is Overlay.
The approach of copying the relevant js, /libs/cq/ui/rte/core/commands/DefaultFormatting.js and adding it under the apps content folder, /apps/cq/ui/rte/core/commands/DefaultFormatting.js I then amended the copy of DefaultFormatting.js copied under apps. AEM then seems to use the 'overlay' technique to apply the strong tag.
Look at this Stackoverflow link :- http://stackoverflow.com/questions/17946117/strong-tag-getting-replaced-to-b-tag-in-cq5
//
you can update the map with an identity mapping (i.e. map b
tags to b
tags) so that nothing gets changed.
Add an htmlRules
node like the following to your dialog.xml (as a sibling of the rtePlugins
node):
...<rtePlugins jcr:primaryType="nt:unstructured">...<misctoolsjcr:primaryType="nt:unstructured"features="sourceedit"/></rtePlugins><htmlRules jcr:primaryType="nt:unstructured"><docType jcr:primaryType="nt:unstructured"><typeConfig jcr:primaryType="nt:unstructured"><semanticMarkupMap jcr:primaryType="nt:unstructured"b="b"i="i"/></typeConfig></docType></htmlRules>... ...
or you can add nodes directly to your dialog in CRXDE Lite if you're not using maven or something similar (this screenshot shows the default, unmodified <i>
to <em>
mapping -- don't forget to change that if that's not what you want):
And to understand Overlay example :- http://experience-aem.blogspot.in/2014/02/aem-cq-56-extend-richtext-editor-add-new-plugin-pullquote....
I hope this would help you.
Thanks and Regards
Kautuk Sahni
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies