类似模版Freemaker,Velocity,Beetl
作用 :基于HTML标签对数据的展示,方便展示对象数据,作用于前后端分离(th:text=""文本显示)
表达式: 标准变量表达式:<span th:text="${user.name}">xxx</span>
选择变量表达式:*{}
URL表达式:<a href="info.html" th:href="@{http://xxxxx}/>"
属性:th:action=@{'/user/info?id='+${user.id}}
th:each="user:${userList}"
th:if="${sex eq '1'}"
th:unless=="${sex eq '1'}" 取反
th:switch="${sex}"
th:case="1"
th:case="*"
th:object
th:src
th:text
th:value
th:attr
th:onclick
th:style
th:method
th:inline="text" [[${user.name}]]
字面量:
文本字面量:''单引号表示,拼接用+ 或者||
数字字面量,
boolean字面量,
null字面量,
内置对象:
#request
#session
功能对象:
#dates,#calendars,#number,#strings,#object,#bools,#arrarys,#lists,#sets,#maps,#aggregates(对数组或集合聚合操作)
Bootstrap:快速开发的WEB 应用程序和网站前端框架,基于javascript css html