当前位置: 动力学知识库 > 问答 > 编程问答 >

java - How to apply check in jsp whether current user is looged in or not

问题描述:

I need a condition in product.tag based on current user is logged in or not?

Can I put this based on spring header.tag file

<div id="userSettings" class="top-nav-bar-layer user-settings header-popup menu-container" style="display:none; right:0;">

<ul data-role="listview" data-inset="true" data-theme="f">

<sec:authorize ifAnyGranted="ROLE_ANONYMOUS">

</sec:authorize>

<li>

</li>

<sec:authorize ifNotGranted="ROLE_ANONYMOUS">

<li>

</li>

</sec:authorize>

</ul>

</div>

网友答案:

Use this tag:

<sec:authorize ifAnyGranted="ROLE_CUSTOMERGROUP"></sec:authorize>
分享给朋友:
您可能感兴趣的文章:
随机阅读: