Browser URL in Sightly

Avatar

Avatar
Boost 5
Level 2
arvind
Level 2

Likes

7 likes

Total Posts

34 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back
Ignite 1
Boost 3
Validate 1
View profile

Avatar
Boost 5
Level 2
arvind
Level 2

Likes

7 likes

Total Posts

34 posts

Correct reply

0 solutions
Top badges earned
Boost 5
Give Back
Ignite 1
Boost 3
Validate 1
View profile
arvind
Level 2

02-09-2020

Dear Team,

 

Is there any way we can print exact browser URL in Sightly HTML?

 

e.g.

1) if Page url is http://localhost:4502/editor.html/content/home.html

 

It should print exact same i.e.  http://localhost:4502/editor.html/content/home.html

 

2) If Page url is http://localhost:4502/content/home.html

 

It should print exactly same i,e http://localhost:4502/content/home.html.

 

Note: I tried with  ${request.requestURL.toString} but in both the cases it prints only 

 

http://localhost:4502/content/home.html. . It ignores editor.html.

 

Thank you in advance.

View Entire Topic

Avatar

Avatar
Validate 1
MVP
Theo_Pendle
MVP

Likes

238 likes

Total Posts

251 posts

Correct reply

105 solutions
Top badges earned
Validate 1
Ignite 5
Ignite 3
Ignite 10
Ignite 1
View profile

Avatar
Validate 1
MVP
Theo_Pendle
MVP

Likes

238 likes

Total Posts

251 posts

Correct reply

105 solutions
Top badges earned
Validate 1
Ignite 5
Ignite 3
Ignite 10
Ignite 1
View profile
Theo_Pendle
MVP

03-09-2020

Hi @arvind,

This is normal for a typical AEM Author instance installation. The reason is that the WCMMODE is EDIT by default on Author instances, which is mentioned in the documentation here: https://helpx.adobe.com/experience-manager/6-3/sites/developing/using/reference-materials/javadoc/co...

In order to simulate a Publisher instance, you must add ?wcmmode=disabled to the URL, regardless of whether /editor.html is present in the URL or not (this is what the View as Published option does).

I demonstrate this in the GIF below:

Peek 2020-09-03 21-17.gif