How can I user data-target="#userId" in a thymeleaf HTML doc. For like ,In any JSP or any HTML ,
<a href="#" data-toggle="modal" data-target="#resetPwModal${customer.uuid }">reset</a>
How I write in a thymeleaf HTML doc. like this?
<a href="#" data-toggle="modal" data-th-target="#resetPwModal${customer.uuid }">reset</a>
the exception is :
org.thymeleaf.exceptions.TemplateProcessingException: Could not parse as expression: "#" (user/userList.html:90)
data-target is used by bootstrap to make your life easier. You (mostly) do not need to write a single line of Javascript to use their pre-made JavaScript components. The data-target attribute should contain a CSS selector that points to the HTML Element that will be changed.
The concept of “target data” “client-scoped” data is the narrowing of the scope of any assessment to solely that data that lies within the scope of the product or service being delivered.
Definition and Usage. URLs with an # followed by an anchor name link to a certain element within a document. The element being linked to is the target element. The :target selector can be used to style the current active target element.
Definition and Usage For <a> and <area> elements, the target attribute specifies where to open the linked document. For <base> elements, the target attribute specifies the default target for all hyperlinks and forms in the page.
th:attr="data-target='#customerModel'+${customer.uuid }"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With