infinite loop
Hi
I am building a web application in JSP where the user need to login
the user input will be sent to loginServlet to be validated
I tried to make the user go to the page he logged in from
first I get the url using
String url = request.getHeader("referer");
then send him back using
RequestDispatcher view = request.getRequestDispatcher(url);
view.forward(request,response);
if the user logged in one the first try it works fine, but if he made a mistake and tried again it will get an error for infinite loop because the url string will refere to the loginServlet
how can I avoid this?
thnx
Message was edited by:
Lich_King

