You are viewing a plain text version of this content. The canonical link for it is here.
Posted to pluto-dev@portals.apache.org by Sunil Patil <pp...@gmail.com> on 2006/08/31 13:51:44 UTC
Proposal for fixing PLUTO-214 Add logout link to portal page.
Hi,
This is first time i am trying to fix issue in Pluto and i am not sure what
is right way for proposing soution so please let me know if posting changes
in dev list is right way.
Problem ->
Jira issue PLUTO-214 says that we should provide a link to user and when
you click on it then user should be logged out. And i thought after logging
out user we should redirect user to login page because that's what Apache
Tomcat is doing.
Proposed Solution ->
1) Since pluto is based on Apache Tomcat and i thought we should have logout
code similar to that Apache Tomcat so i had created a simple logout.jsp like
this
<%
session.invalidate();
request.getSession(true);
response.sendRedirect("/pluto/portal");
%>
This code is similar to org.apache.webapp.admin.LogOutAction code used by
Apache Tomcat when you click on admin logout link.
2) Then i made one change in pluto-default-theme.jsp to add link to
logout.jsp page like this
<table width="100%">
<tr>
<td align="right"><a href="/pluto/logout.jsp">Log out</a></td>
</tr>
</table>
This table should be added just before navigation div you can search for
<div id="navigation"> text and add this table just above that
How to test this solution ->
1) Copy logout.jsp in <PLUTO_HOME>\webapps\pluto folder
2) Change pluto-default-theme.jsp to add link to logout page.
Please let me know what do you think about this fix.
Sunil