【发布时间】:2020-07-05 05:46:27
【问题描述】:
我的主页没有显示用户名,我正在使用 sec:authentication 标签
<li sec:authorize="isAuthenticated()"><a th:href="@{/logout}">Logout</a></li>
</ul>
</div>
</nav>
<br><br>
<p>
Welcome <span sec:authentication="principal.username">User</span>
</p>
【问题讨论】:
-
对this question的任何答案有帮助吗?
标签: spring-boot thymeleaf