AEM 6.5 <B> to <strong> in RTE

Avatar

Avatar

JakeCham

Avatar

JakeCham

JakeCham

07-01-2021

I have a requirement that <b> tag should be converted into <strong> after submitting. I was able to achieve this by introducing below node structure as a sibling to rtsPlugins of my text component in apps.

<htmlRules jcr:primaryType="nt:unstructured">
    <docType jcr:primaryType="nt:unstructured">
         <typeConfig jcr:primaryType="nt:unstructured">

                   @useSemanticMarkup Boolean true         

         </typeConfig>
     <docType
<htmlRules

Problem is in our site already we have used RTE for more that 500 odd places and those RTE ,The new change is not getting reflected unless manually editing those RTE components(need to hit twice B icon).Is there anyway to overcome that existing RTE s in pages not getting reflected that change <b> to <strong>.

Thanks in advance. 

View Entire Topic

Avatar

Avatar

Ravi_Pampana

MVP

Avatar

Ravi_Pampana

MVP

Ravi_Pampana
MVP

07-01-2021

Hi,

 

You can try replacing the <b> to <strong> in java while reading value from node property and displaying in htl. This will not replace <b> to <strong> in the jcr node but for in html it will have <strong> instead of <b> for already added rte's.