Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
BedrockMission!

Learn More

View all

Sign in to view all badges

AEM 6.3 SP2 - Replace <b> with <strong> and <i> with <em> in Rich Text Editor

Avatar

Avatar
Boost 3
Level 1
silkyk66254620
Level 1

Likes

3 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Boost 3
Boost 1
View profile

Avatar
Boost 3
Level 1
silkyk66254620
Level 1

Likes

3 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Boost 3
Boost 1
View profile
silkyk66254620
Level 1

14-05-2018

Hi All,

I want to replace <b> with <strong> and <i> with <em> in rte in AEM 6.3 SP2. I already tried below solutions but no luck as they all are for AEM 6.1.

1. Experiencing Adobe Experience Manager - Day CQ: AEM 61 - Touch UI Rich Text Editor Remove Bold and A...

2. Overriding '/libs/clientlibs/granite/richtext/core/js/commands/DefaultFormatting.js' with <b> to <strong>

3. Adding 'semanticMarkupMap' node in rte for changing of <b> to <strong>.

Whenever i author rte in dialog, it changes <b> to <strong> but the moment i click ok or 'view Source', it changes back to <b>.

Can you please provide some inputs?

Replies

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

14-05-2018

Did you follow this article exactly - enter all of the plug-in code?

Avatar

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile

Avatar
Validate 25
Level 10
smacdonald2008
Level 10

Likes

1,409 likes

Total Posts

12,671 posts

Correct Reply

2,278 solutions
Top badges earned
Validate 25
Validate 10
Validate 1
Give back 900
Give back 600
View profile
smacdonald2008
Level 10

14-05-2018

Also - we are checking with the author to see if there is an updated version of this article.

Avatar

Avatar
Boost 3
Level 1
silkyk66254620
Level 1

Likes

3 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Boost 3
Boost 1
View profile

Avatar
Boost 3
Level 1
silkyk66254620
Level 1

Likes

3 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Boost 3
Boost 1
View profile
silkyk66254620
Level 1

15-05-2018

Yeah i did all the steps but still was not able to see the new Strong plugin. Can you provide any package or newer version of article specific to AEM 6.3?

Avatar

Avatar
Level 1
FredrickDominy
Level 1

Likes

0 likes

Total Posts

3 posts

Correct Reply

0 solutions
View profile

Avatar
Level 1
FredrickDominy
Level 1

Likes

0 likes

Total Posts

3 posts

Correct Reply

0 solutions
View profile
FredrickDominy
Level 1

13-06-2018

I've had luck with adding this as a sibling to the RTE dialog's <uiSettings> and <rtePlugins> nodes.

<htmlRules jcr:primaryType="nt:unstructured">
  <docType jcr:primaryType="nt:unstructured">
  <typeConfig jcr:primaryType="nt:unstructured"
   useSemanticMarkup="{Boolean}true">
  <semanticMarkupMap
   b="strong"
   i="em"/>
  </typeConfig>
  </docType>
</htmlRules>

Note that if text has already been authored with <b> and <i> tags you will need to go in and add a space somewhere in the rte editor to pick up the change and swap the tags.

Avatar

Avatar
Level 1
PushparajanR
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile

Avatar
Level 1
PushparajanR
Level 1

Likes

0 likes

Total Posts

1 post

Correct Reply

0 solutions
View profile
PushparajanR
Level 1

06-08-2018

We are also facing same issue. Any solution available now?

Avatar

Avatar
Validate 1
Level 1
cqcoder
Level 1

Likes

2 likes

Total Posts

8 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile

Avatar
Validate 1
Level 1
cqcoder
Level 1

Likes

2 likes

Total Posts

8 posts

Correct Reply

1 solution
Top badges earned
Validate 1
Boost 1
Affirm 1
View profile
cqcoder
Level 1

31-08-2018

Fedrick,

<semanticMarkupMap
   b="strong"
   i="em"/>

shouldn't it be

<typeConfig jcr:primaryType="nt:unstructured"

   useSemanticMarkup="{Boolean}true">

  <semanticMarkupMap jcr:primaryType="nt:unstructured"

   b="strong"

   i="em"/>

</typeConfig>

not sure, how without jcr:primaryType="nt:unstructured" we can enter the value.

Please clarify.. I tried it as a node, but still not working... Im on AEM 6.4

Avatar

Avatar
Give Back
Employee
hibikik74610607
Employee

Likes

2 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile

Avatar
Give Back
Employee
hibikik74610607
Employee

Likes

2 likes

Total Posts

2 posts

Correct Reply

0 solutions
Top badges earned
Give Back
Boost 1
View profile
hibikik74610607
Employee

29-09-2018

I got the knowledge of this resolution from my colleague so I post the knowledge instead of my colleague.

The best practice is as follows in AEM6.4.

1. cq:editConfig

/apps/core/wcm/components/text/v2/text/cq:editConfig/cq:inplaceEditing/config/htmlRules/do cType/typeConfig

     @useSemanticMarkup [boolean] = true

/apps/core/wcm/components/text/v2/text/cq:editConfig/cq:inplaceEditing/config/htmlRules/d ocType/typeConfig/semanticMarkupMap

     @b [String] = "strong"

     @i [String] = "em"

RTE_1.png

2. cq:dialog

(a) Add a property "features" to rtePlugins/misctools node.

/apps/core/wcm/components/text/v2/text/cq:dialog/content/items/tabs/items/properties/items/columns/items/column/items/text/rtePlugins/misctools

     @features [String] = "*"

RTE_3.png

(b) Add misctools#sourceedit in "toolbar" properties of the below nodes.

/apps/core/wcm/components/text/v2/text/cq:dialog/content/items/tabs/items/properties/items/columns/items/column/items/text/uiSettings/cui/inline

/apps/core/wcm/components/text/v2/text/cq:dialog/content/items/tabs/items/properties/items/columns/items/column/items/text/uiSettings/cui/dialogFullScreen

RTE_4.png

(c) Create the following node structure and set properties same as "1. cq:editConfig".

/apps/core/wcm/components/text/v2/text/cq:dialog/content/items/tabs/items/properties/items/columns/items/column/items/text/htmlRules/docType/typeConfig

     @useSemanticMarkup [boolean] = true

/apps/core/wcm/components/text/v2/text/cq:editConfig/cq:inplaceEditing/config/htmlRules/d ocType/typeConfig/semanticMarkupMap

     @b [String] = "strong"

     @i [String] = "em"

Best,

Avatar

Avatar
Level 1
srikary71884977
Level 1

Likes

0 likes

Total Posts

5 posts

Correct Reply

0 solutions
View profile

Avatar
Level 1
srikary71884977
Level 1

Likes

0 likes

Total Posts

5 posts

Correct Reply

0 solutions
View profile
srikary71884977
Level 1

21-01-2019

Hi hibikik39369812​,

i tried the above said thing but i am not able to get strong or em tags , infact the bold and italic tags are vanished from my dialog. Is there any other way to do it?

regards,

Srikar.Y

Avatar

Avatar
Boost 250
MVP
Gaurav-Behl
MVP

Likes

250 likes

Total Posts

1,147 posts

Correct Reply

283 solutions
Top badges earned
Boost 250
Establish
Give back 300
Give Back 50
Give Back 5
View profile

Avatar
Boost 250
MVP
Gaurav-Behl
MVP

Likes

250 likes

Total Posts

1,147 posts

Correct Reply

283 solutions
Top badges earned
Boost 250
Establish
Give back 300
Give Back 50
Give Back 5
View profile
Gaurav-Behl
MVP

22-01-2019

Could you share screenshots/steps that you performed? Do you see any errors in console log?

What version of AEM do you use?