Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

AEM understands touch/classic view

Avatar

Level 4

Hi Friends,

How AEM able to understand internally with editor.html aem pages should be displayed in touch view if I have cf# the page should be displayed in classic view?

Regards

Pr@veen

1 Accepted Solution

Avatar

Correct answer by
Administrator

Hi

Please have a look at the explanation:-  

  1. Let the URL be:- http://localhost:4502/editor.html/content/we-retail.html   (i.e. http://localhost:4502/editor.html/.... )
  2. Request processing will start resource resolution, there in the URL they will see that Script to run is editor.html and here in our case it’s a vanity path, to it will result in calling “/libs/cq/gui/content/editor.html”(actual path of the Script).
  3. From there the “sling:resourceType” is taking us to “cq/gui/components/authoring/editors/switch”, here the editing part of Touch UI would be catered.

Similarly for cf# its -> cq/ui/components/widget -> cq/ui/components/widget -> /libs/cq/ui/components/widget/html.jsp

Here’s one way to look for Resource resolution:

  1. Head over to http://localhost:4502/system/console/servletresolver
  2. Enter the request URL and select the appropriate HTTP method (http://localhost:4502/editor.html/content/we-retail.html)
  3. The Opting servlets will be listed – I think the ‘chosen’ one is on the top…

 

Here’s another:

  1. Head over to http://localhost:4502/system/console/requests and clear existing requests
  2. ‘Edit’ a ‘simple’ AEM site (e.g. navigate to http://localhost:4502/editor.html/content/we-retail.html)
  3. Refresh the page in #1 and locate your request
    1. It may happen that the page you are interesting in sends more than 20 requests – perhaps there’s a configuration to increase how many requests are ‘kept’ for analysis but I don’t know of it – instead, what you can try is to ‘cancel’ the page-load (so that further requests are not sent to the server)

 

The downside of 2nd method is limited requests can be tracked this way – the upside is that you get a lot more information that the 1st.

 

I hope this would help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni

View solution in original post

2 Replies

Avatar

Correct answer by
Administrator

Hi

Please have a look at the explanation:-  

  1. Let the URL be:- http://localhost:4502/editor.html/content/we-retail.html   (i.e. http://localhost:4502/editor.html/.... )
  2. Request processing will start resource resolution, there in the URL they will see that Script to run is editor.html and here in our case it’s a vanity path, to it will result in calling “/libs/cq/gui/content/editor.html”(actual path of the Script).
  3. From there the “sling:resourceType” is taking us to “cq/gui/components/authoring/editors/switch”, here the editing part of Touch UI would be catered.

Similarly for cf# its -> cq/ui/components/widget -> cq/ui/components/widget -> /libs/cq/ui/components/widget/html.jsp

Here’s one way to look for Resource resolution:

  1. Head over to http://localhost:4502/system/console/servletresolver
  2. Enter the request URL and select the appropriate HTTP method (http://localhost:4502/editor.html/content/we-retail.html)
  3. The Opting servlets will be listed – I think the ‘chosen’ one is on the top…

 

Here’s another:

  1. Head over to http://localhost:4502/system/console/requests and clear existing requests
  2. ‘Edit’ a ‘simple’ AEM site (e.g. navigate to http://localhost:4502/editor.html/content/we-retail.html)
  3. Refresh the page in #1 and locate your request
    1. It may happen that the page you are interesting in sends more than 20 requests – perhaps there’s a configuration to increase how many requests are ‘kept’ for analysis but I don’t know of it – instead, what you can try is to ‘cancel’ the page-load (so that further requests are not sent to the server)

 

The downside of 2nd method is limited requests can be tracked this way – the upside is that you get a lot more information that the 1st.

 

I hope this would help you.

Thanks and Regards

Kautuk Sahni



Kautuk Sahni