I know this is in the forum a lot , but I can't get this to work. I have two jsp's on seperate servers. I load the first page by calling the first jsp like: http://server1.com/jsp1.jsp. jsp1.jsp then redirects to another server, over ssl, and calls jsp2.jsp. I need to send a String value from jsp1 to jsp2, but I also need to know the referer. Unfortunately it is always null. Can anyone tell me what is wrong with this code? Should this work?
Thanks,
James
jsp1:
<%@ page import="java.util.*,java.io.*,java.text.*,java.net.*" %>
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html;CHARSET=iso-8859-1">
<TITLE>jsp1</title>
</head>
<BODY BGCOLOR="white">
<%
response.sendRedirect("https://server2.com/jsp2.jsp");
%>
</body>
</html>
jsp2:
<%@ page import="java.util.*,java.io.*,java.text.*,java.net.*" %>
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html;CHARSET=iso-8859-1">
<TITLE>jsp2</title>
</head>
<BODY BGCOLOR="white">
<%
String ref = getHeader("Referer");
out.write(ref);
%>
</body>
</html>