Sightly issue with URLs if it doesn't have .html extension | Community
Skip to main content
Level 3
Sep 13, 2016 10:26 AM UTC

Sightly issue with URLs if it doesn't have .html extension

Hello everyone,

I have a URL for example "http://help-forums.adobe.com/content/adobeforums:test/" when I provide this URL in href, the output that i get is "http://help-forums.adobe.com/content/_adobeforums_test/". 

More Details:

Suppose properties.link = http://help-forums.adobe.com/content/adobeforums:test/

<a href="${properties.link @ context='unsafe'}">Support </a> //this doesn't work

but if i append .html at the end of the URL it works.

<a href="${properties.link @ context='unsafe'}.html">Support </a> //this works

Why doesn't it work when we don't have .html in the URL?

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

joerghoh
Employee
Sep 14, 2016 8:18 PM UTC

Hi,

if the question about the ":" character: This character is special and if it's encountered the namespace mangling of Sling kicks in and translates it into "_namespace_".

Translate
kautuk_sahni
Employee
Sep 14, 2016 5:50 AM UTC

As correctly pointed by Feike, 

This is sling resolution, please have a look at this URL to Script Resolution documentation :-

Link:- https://docs.adobe.com/docs/en/aem/6-2/develop/the-basics.html

[img]https://docs.adobe.com/content/docs/en/aem/6-2/develop/the-basics/_jcr_content/contentbody/image_1.img.png/1321988332428.png[/img]

 

Preference order is Selector + Extention > Selector > Extention > Method of call (get,post etc).

~kautuk

Translate
Kautuk Sahni
Feike_Visser1
Employee
Sep 13, 2016 12:04 PM UTC

This is Sling related, with the extension you basically point how you want to render the content.

Translate