Disable Link Filtering in AEM

sagrawal

30-08-2020

I need help on hyperlink filtering in response and flow if like below.

1. I have article data response in article data JSON response (we recived pasre JSON)

 [Actual Response from Service provider]

{
"article": [
{
"name": "Test links",
"content": "<p>test <a href=\"https://en.wikipedia.org/wiki/Season\">Teslink</a></p>"
}
]
}

 [Getting response from singlet servlet] [public class ArticleServlet extends SlingSafeMethodsServlet]

 

{"article":[{"name":"Test links","approverOrderNumber":0,"content":"<p>test <img class="cq-LinkChecker cq-LinkChecker--prefix cq-LinkChecker--invalid" src="/libs/cq/linkchecker/resources/linkcheck_o.gif" alt="invalid link: \" title="invalid link: \" border="0">eGain1<img class="cq-LinkChecker cq-LinkChecker--suffix cq-LinkChecker--invalid" src="/libs/cq/linkchecker/resources/linkcheck_c.gif" border="0"></p>"
}
]
}

 

 

So its unnecessary adds "LinkChecker cq-LinkChecker--prefix cq-LinkChecker--invalid" these link in contents and its break everything in response.  

 

How can we stop link checker service in aem itself.

 

one method i seen is adding "x-cq-linkchecker="skip" but is there any other solution ?

 

Is it mandatory to add "x-cq-linkchecker="skip" in link ?

 

 
 

I tried below also then it removed "href" completely and send value as "href=/" in response.

image.png

 

 

Accepted Solutions (1)

Accepted Solutions (1)

Singaiah_Chintalapudi

MVP

30-08-2020

If you're referring this on publisher then, you should disable all Link Checker service configs.

 

On author, try modifying the Day CQ Link Checker Transformer: remove a:href from the Rewrite Elements config.

Answers (0)