thymeleaf
tinysakurac
蹒跚学步的猿
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
关于thymeleaf th:replace th:include th:insert 的区别
关于thymeleaf th:replace th:include th:insert 的区别th:insert :保留自己的主标签,保留th:fragment的主标签。th:replace :不要自己的主标签,保留th:fragment的主标签。th:include :保留自己的主标签,不要th:fragment的主标签。(官方3.0后不推荐)需要替换的片段内容:<foot...转载 2018-10-06 17:49:18 · 721 阅读 · 0 评论 -
thymeleaf中的简单表达式
变量表达式 ${… …}<input type="text" name="userName" value="James Carrot" th:value="${user.name}" />上述代码为引用user对象的name属性值。变量表达式支持一些简单的逻辑运算以及三目运算符,如:<span th:text="${user.popedom==0?'管理员':'普通用户转载 2018-10-06 18:40:19 · 1181 阅读 · 0 评论 -
thymeleaf常用标签
1.1 th:text 用于文本的显示,并且可以进行简单的计算。<td th:text="${username}">mlm</td> -> <td>maliming</td><td th:text="9+7">2018</td> -> <td&转载 2018-10-06 18:58:58 · 2760 阅读 · 0 评论 -
thymeleaf内置对象
Thymeleaf模板引擎之内置对象一、简介 和JSP一样,Thymeleaf也是具有内置对象一说的,笔者在这里会进一步搜集和汇总thymeleaf常用的内置对象。为了能够进一步详细讲解这一段的使用方法,基于官网,并且翻阅同行前辈们的资料的基础上,详细汇编出这一章的内容,用于笔者技术水平有限,错误之处在所难免,敬请各位读者谅解和提出宝贵的意见和建议。二、基础对象1、ctx: th...转载 2018-10-06 19:14:29 · 3767 阅读 · 0 评论
分享