Using Thymeleaf in order to generate a URL with params and nested variables in it

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Using Thymeleaf in order to generate a URL with params and nested variables in it

balteo
I am trying to use Thymeleaf in order to generate a URL with params.

<a th:with="baseUrl=${websiteContext} + '/#/email/activate/'" th:href="@{${baseUrl}(token=${member.token},newEmail=${requestedEmail})}" >Activate email</a>

generates the following link:

http://localhost:8080/?token=1a964190-7807-47ee-a36b-e3712eeb24f4&newEmail=balteo%2540yahoo.fr#/email/activate/
However the literal string /#/email/activate/ always ends up at the end of the url...

Note that I need the #  within the url as my front end is based on angular.

Can anyone please help?