Subversion Repositories Sigmater

Rev

Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
6 Andrea 1
<%@ page language="java" contentType="text/html; charset=ISO-8859-1" pageEncoding="ISO-8859-1"%>
2
<%@page import="org.sigmater.srm.SrmUser"%>
3
<html>
4
	<head>
5
		<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
6
		<title>Redirect ...</title>
7
	</head>
8
	<body>
9
	<%
10
		String homeUrl = "http://" + request.getServerName() + ":" + 
11
			request.getServerPort() + "/" + request.getContextPath();
12
 
13
		String navigatoreUrl = request.getParameter("navigatoreUrl");
14
 
15
		SrmUser user = (SrmUser) session.getAttribute("principal");
16
 
17
		if (user == null || navigatoreUrl == null) {
18
			response.sendRedirect(homeUrl);			
19
		} else {
20
			response.sendRedirect(navigatoreUrl + "?token=" + user.getTokenId());
21
		}
22
	%>
23
	</body>
24
</html>
25