thymeleaf - How to stop character encoding in thymeleaf from changing url get parameter '?' character to changing to %3F
问题描述
code is like:-
<a th:href="@{{path}(path=${templatebitcointalkforumlink})}"
and from properties file:-
eg:- template variable=https://bitcointalk.org/index.php?topic=4456828
Note:- i don't own this post/topic it's just example
now it changes to:-
https://bitcointalk.org/index.php%3Ftopic=4456827
解决方案
You shouldn't be using @{...}
if you don't want to take advantage auto encoded parameters, url replacement params, etc.. Instead, just use a regular variable.
<a th:href="${templatebitcointalkforumlink}">...</a>
推荐阅读
- python - 如何获取一些数据框列的字符串?
- angular - 在Angular中使用复选框选择列
- html - 对齐主要部分中的图像
- vue.js - 从mounted中调用的方法更新数据值
- autodesk-forge - BIM360 文档中删除的文件夹和 BIM360 数据管理 API 中的 hidden:true 不会渗透到子级
- python - 如何将 GEKKO 解决方案转换为浮点数
- r - 如何在 rmarkdown/knitr 中顺序输出部分(基数 r)图?
- c# - c# - Microsoft Graph API - DriveItem 上的权限不起作用
- c++ - 用户定义文字的每次“正常”使用都是未定义的行为吗?
- addeventlistener - addEventListeners 覆盖其他 EventListeners