Win a copy of Think Java: How to Think Like a Computer Scientist this week in the Java in General forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Selection List Change not updated

 
curtis harrison
Greenhorn
Posts: 8
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a JSP page (page1) with a dynamic <select> list. When the user first gets to the page, nothing is selected. They select an item, click a button, and the correct item is sent to the next page (page2). However, from page 2, if the user presses the browser's back button, they go back to page 1, the same list is displayed with their previous selection highlighted. When they change the selection and click the 'next' button, they go to page 2, but the FIRST selection they had made is sent to page 2, not the most recent selection.
If they press the browser's back button and see the list with a selected item, and then press the browser's refresh button, the selection in the list is unselected. They can make a new selection, press the 'next' button, and the CORRECT item appears.
Is there a way for me to force a 'refresh' when a page 1 loads, or FORCE some kind of 'unselect' on the selection list when the page is revisited. I don't EVER want an item to be initally selected in the selection list.
Is there a command to 'unselect' all items in the list?
Thanks,
Curtis
 
Mike Curwen
Ranch Hand
Posts: 3695
IntelliJ IDE Java Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It sounds like a browser caching problem.

There are a LOT of posts on here about this, do a search for all the META tag, and JSP solutions for this.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic