I have account.jsp which opens depending on username and password dialog form.
<sql:query dataSource = "${snapshot}" var = "korisnici">
SELECT * FROM clanovi WHERE username='<%=request.getParameter("user")%>' AND lozinka='<%=request.getParameter("pass")%>' and id_naloga !='1';
</sql:query>
And it goes with for-each loop and shows all the info about that user in the html form.
When I press update(type=submit) it does form action on another samostalno_azuriranje.jsp page which updates the info.
UPDATE clanovi SET ime='<%=request.getParameter("name")%>', prezime ='<%=request.getParameter("last_name")%>',username='<%=request.getParameter("username1")%>',lozinka= '<%=request.getParameter("password")%>',email= '<%=request.getParameter("email1")%>', datum_rodjenja= '<%=request.getParameter("date")%>',pol= '<%=request.getParameter("gender")%>',adresa='<%=request.getParameter("address")%>',broj_tel='<%=request.getParameter("phone")%>' ,slika='<%=request.getParameter("slika")%>' where id_clan=<%=request.getParameter("id_clan")%> and id_naloga= <%=request.getParameter("user1")%>;
<%
String redirectURL = "account.jsp";
response.sendRedirect(redirectURL);
%>
So,the problem comes with the refreshing the page. I am trying to get my account again (updated) but with sending redirect it will only show empty account.jsp page. Only way it works is by pressing a back button in the browser. IS there a way to simulate a back browser button function automatically?