When I use
<h2 class="${properties.testclass}" data-sly-element="${properties.tagType}">${properties.title}</h2> in my JSP code (In HTML it works fine)
Output
<h2 class="test" data-sly-element="h5">Title</h2>
Expected Output:
<h5 class="test" >Title</h5>
Solved! Go to Solution.
Views
Replies
Total Likes
No!! (As far as I know ) Feike Visser should be the best person to answer this if my understanding is wrong
Thanks
Veena
Views
Replies
Total Likes
Hi
Please be informed that data-sly attributes can be used only in context with HTL . That means , if you are writing your presentation logic in sightly , you are good to go and this will work like magic .
As sightly was developed mainly for us to move away from the far old JSP , I would recommend you to move to HTL than trying this in JSP
I have found some interesting reading for you here AEM 6 Why Sightly?
Thanks
Veena
Views
Replies
Total Likes
Thanks Veena.
I know moving to HTL solves the issue. My question was is it achievable with JSP?
Views
Replies
Total Likes
No!! (As far as I know ) Feike Visser should be the best person to answer this if my understanding is wrong
Thanks
Veena
Views
Replies
Total Likes
That syntax only works in HTL - not JSP
Views
Replies
Total Likes
Views
Likes
Replies