Hey All,
Is it possible for Sling to map one resource to multiple views. Say I have a component @ /apps/<site>/components/breadcrumb and this has multiple views under /etc/1/components/breadcrumb/view.jsp and /etc/2/components/breadcrumb/view.jsp, I want Sling to check if view is present in /etc/2 hierarchy then pick that one else pick the one in etc/1 hierarchy . Is it possible to implement this with current Sling Resource Resolver ?
Regards
Shivika
Solved! Go to Solution.
Views
Replies
Total Likes
Hi Shivika,
Read about selectors which should ideally solve your problem. Some articles are given below for your reference.
http://blogs.adobe.com/contentmanagement/tag/selectors/
https://docs.adobe.com/docs/v5_1/html-resources/cq5_guide_developer/ch02s08.html
http://www.citytechinc.com/us/en/blog/2013/08/apache-sling-selectors-request-parameters.html
Regards
Tuhin
Views
Replies
Total Likes
Similar functionality can be achieved through using the selectors in the request url. You can have multiple views/jsp according to your design and need in your component level.
Refer the below url for more information on selectors.
https://docs.adobe.com/docs/en/aem/6-1/develop/the-basics.html#Locating the script
Views
Replies
Total Likes
Hi Shivika,
Read about selectors which should ideally solve your problem. Some articles are given below for your reference.
http://blogs.adobe.com/contentmanagement/tag/selectors/
https://docs.adobe.com/docs/v5_1/html-resources/cq5_guide_developer/ch02s08.html
http://www.citytechinc.com/us/en/blog/2013/08/apache-sling-selectors-request-parameters.html
Regards
Tuhin
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies