Issue with tel:+ Links in Rich Text Component | Community
Skip to main content
aravindreddyyesugari18079
Level 2
August 9, 2024
Question

Issue with tel:+ Links in Rich Text Component

  • August 9, 2024
  • 4 replies
  • 2854 views

Hello Adobe Community,

I'm encountering an issue with the Rich Text component in AEM when adding a tel: hyperlink.

Scenario:

I add a hyperlink with the format tel:+1234567890 in the Rich Text component's dialog.
After clicking "Done," the link behaves as expected on the page, opening the prompt to initiate a call when clicked.
The link is also correctly stored in the repository as tel:+1234567890.
Problem:

When I reopen the dialog to edit the link, the hyperlink is stripped, and the text appears as plain text, losing the hyperlink functionality in the dialog.
Interestingly, if I use tel:1234567890 (without the +), the link is preserved when reopening the dialog.
Has anyone else experienced this issue or have any suggestions on how to resolve it?

Thank you in advance for your help!

Best regards,
Aravind Yesugari

4 replies

aravindreddyyesugari18079
Level 2
August 9, 2024

Hi @arunpatidar 

The issue I was facing is that when I am adding + character when I add tel:1234567890 the link is not getting striped ,when I try to add tel:+1234567890  then  the href is getting striped, and in the page it is rendering as link and showing the expected behavior but when i re open the dialog in dialog I am not able to unlink it  in dialog its showing as normal word but in page its rendering as link and if see in the repo as well its storing as tel:+1234567890.

I tried overlaying

/libs/cq/xssprotection/config.xml in /apps - /apps/cq/xssprotection/config.xml

Add the protocol, say telURL

<regexp name="telURL" value="tel:[0-9]+"/>

and Added telURL configuration to the accepted list of anchor href

<attribute name="href">
<regexp-list>
<regexp name="onsiteURL"/>
<regexp name="offsiteURL"/>
<regexp name="telURL"/>
</regexp-list>
</attribute>


as well but that doesn't worked .


kapil_rajoria
Community Advisor
Community Advisor
August 10, 2024

Hi @aravindreddyyesugari18079 did you add "tel:" to the Link Checker Special Link Prefixes in the configuration: com.day.cq.rewriter.linkchecker.impl.LinkCheckerImpl. Search the configuration here:

http://localhost:4502/system/console/configMgr/

In my case, I was using a textfield and doing only the above worked fine for me. I also didn't touch the xssprotection config.

 

kautuk_sahni
Community Manager
Community Manager
September 13, 2024

@aravindreddyyesugari18079 Did you find the suggestions helpful? Please let us know if you require more information. Otherwise, please mark the answer as correct for posterity. If you've discovered a solution yourself, we would appreciate it if you could share it with the community. Thank you!

Kautuk Sahni
Suraj_Kamdi
Community Advisor
Community Advisor
December 2, 2024

@aravindreddyyesugari18079 This is the problem with AEM cloud instance. RTE will not accept the special characters like +,( and white space etc. so whenever you want to author telephone number just put tel:919876543210 instead of tel:+919876543210 or any country pattern.

New Member
May 6, 2025

Handing International Numbers Link Href in Rich Text Editor :

After doing the above mentioned steps,if I configure tel:12345 in rte it works fine, but when using href=tel for international numbers  i.e., href=tel:+61.... AEM removes the link and it start stripping the code.So need to follow the below step to make it work.

 

By default, the RTE supports these protocols in href:http://,https://,ftp://,mailto:

To configure an additional protocol, you will have to add the following structure in the RTE at the same level of the rtePlugins node, The definition of this node will be:

 

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

<links

jcr:primaryType="nt:unstructured"

protocols="[http://,https://,ftp://,mailto:,tel:]" />

</htmlRules>

 

And that's how the issue can be resolved.

Level 3
October 14, 2025

@arunpatidar  I am also facing same issue, but as per the above comments i have implemented nothing is working, Does AEM as Cloud support tel:+12234452 "+" is supported or will it get striped off?

 

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

<links

jcr:primaryType="nt:unstructured"

protocols="[http://,https://,ftp://,mailto:,tel:]" />

</htmlRules>
tried this as well didnt worked.