Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

refreshing page

 
Jyoti Jadhav
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
in jsp page(enter_product_data.jsp) i am entering product details and on submit i am checking product id for duplicate records and if product id exists in database i am showing a page having error message.

for coming from servlet to error message page i used requestdiapatcher's forward method.

that page contains back button.

back button onclick i wrote script.
function backgo()
{
document.form1.action="enter_product_data.jsp"
document.form1.submit()
}

but when i come to this enter_product_data.jsp page again i want all the datails as it is.what is the way to get it.
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34187
340
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Jyoti,
The best way is to store the values in the HttpSession before going to the error page. That way the next time you paint the JSP, they are available to you.
 
Jyoti Jadhav
Greenhorn
Posts: 18
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Jeanne Boyarsky:
Jyoti,
The best way is to store the values in the HttpSession before going to the error page. That way the next time you paint the JSP, they are available to you.


Hey Jeanne,

Thanks a lot..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic