I want to add one extra attribute in AEM generated divs
Eg: Normally I get as below
<div class="parbase component section"></div>
I want to add an attribute like
<div class="parbase component section" newattribute> </div>
Solved! Go to Solution.
I dont think so this provides an options to add attribute instead of class.
I would suggest you to create extra DIV in your HTML for this attribute.
OR
Write a 3-4 lines of JS code to Add this attribute.
Could you please elaborate your use case?
thanks
Views
Replies
Total Likes
You need to create cq:HtmlTag for this use case. Check this article - http://dev.day.com/cemblog/en/experiencedelivers/2013/04/modify_the_auto-generateddivs.html
If you are looking to avoid these automatic div's denerated by AEM, use "cq:noDecoration" property. This way extra div's, apart from your html will not be generated.
Views
Replies
Total Likes
I wanted to add in <div class="parbase target section"></div>
Not for the component , but if it is targeted, i need to add the attribute in above div which is not a part of component
Views
Replies
Total Likes
I want to use IncludeOptions to add attribute instead of class. Is it possible ?
Views
Replies
Total Likes
I dont think so this provides an options to add attribute instead of class.
I would suggest you to create extra DIV in your HTML for this attribute.
OR
Write a 3-4 lines of JS code to Add this attribute.
Could you please elaborate your use case?
thanks
Views
Replies
Total Likes
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies
Views
Likes
Replies