开发者

Spring security logout link in Facelets

I used to have JSPs implementing spring security logout like this:

<a id="logout" href="&开发者_运维知识库lt;spring:url value="/j_spring_security_logout" htmlEscape="true" />">Logout</a>

Later on when I changed to jsf 2, and started using Facelets, I can't get it to work anymore. I tried many ways. I tried this:

<a id="logout" href="&lt;spring:url value=&quot;/j_spring_security_logout&quot; htmlEscape=&quot;true&quot; &sol;&gt;">Logout</a>

But it wont work. Can someone please help me? I really appreciate your help.


Just

<a href="#{request.contextPath}/j_spring_security_logout">logout</a>

or

<h:outputLink value="/j_spring_security_logout">logout</h:outputLink>


There are two solutions:

<a href="#{request.contextPath}/j_spring_security_logout">Logout1</a>
<h:outputLink value="#{request.contextPath}/j_spring_security_logout">Logout2</h:outputLink>
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜