<form method="get" th:action="@{/logout_html}" id="userinfo"> <button type="submit" class="btn btn-link">退出</button> <b style="display:inline;" th:text="'用户名:' + ${session.loginUser}"></b> </form>
关键代码:session.loginUser
<form method="get" th:action="@{/logout_html}" id="userinfo"> <button type="submit" class="btn btn-link">退出</button> <b style="display:inline;" th:text="'用户名:' + ${session.loginUser}"></b> </form>
关键代码:session.loginUser
转载于:https://www.cnblogs.com/jums/p/11343902.html