'Thymeleaf: Use a link with 'th:href' in Javascript
I have the following link:
<a th:href="@{/linkToPage}">...</a>
which works. But now I have a workaround where I have to "create" this link in Javascript:
$('#div').html(
'<a th:href="@{/linkToPage}">...</a>'
);
but now the link does not work anymore. Is there a way to get link work and call the corresponding 'get' method in the controller? Thank you very much.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
