I2P Address: [http://git.idk.i2p]

Skip to content
Snippets Groups Projects
Commit 3131e65b authored by zzz's avatar zzz
Browse files

fix redirection; change header

parent 1997be37
No related branches found
No related tags found
No related merge requests found
......@@ -138,7 +138,7 @@ function initAjax() { setInterval(requestAjax1, 15000); }
<jsp:useBean class="net.i2p.router.web.HomeHelper" id="homehelper" scope="request" />
<jsp:setProperty name="homehelper" property="contextId" value="<%=(String)session.getAttribute(\"i2p.contextId\")%>" />
<div class="ag2">
<h4 class="app"><%=intl._("Recommended Eepsites")%></h4>
<h4 class="app"><%=intl._("Eepsites of Interest")%></h4>
<jsp:getProperty name="homehelper" property="favorites" /><br>
</div>
<div class="ag2">
......
<%@page contentType="text/plain"%>
<%@page pageEncoding="UTF-8"%>
<%
//
// Redirect to either /home or /console, depending on configuration,
// while preserving any query parameters
//
response.setStatus(302, "Moved");
String req = request.getRequestURI();
String req = request.getRequestURL().toString();
StringBuilder buf = new StringBuilder(128);
if (req.endsWith("index"))
req = req.substring(0, req.length() - 5);
else if (req.endsWith("index.jsp"))
req = req.substring(0, req.length() - 9);
buf.append(req);
if (!req.endsWith("/"))
req += '/';
buf.append('/');
boolean oldHome = net.i2p.I2PAppContext.getGlobalContext().getBooleanProperty("routerconsole.oldHomePage");
if (oldHome)
req += "console";
buf.append("console");
else
req += "home";
response.setHeader("Location", req);
buf.append("home");
String query = request.getQueryString();
if (query != null)
buf.append('?').append(query);
response.setHeader("Location", buf.toString());
%>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment