Here I am a little delicate. In my organization, we are developing inventory management systems, and this is a web application based on JSP pages and servlets that process them.
I was asked to fix a specific problem. We have a JSP page with an HTML form table that has stock information. When a user enters data manually and submits a form, inventory data is updated in the database and works great.
The problem is this: when the user clicks the return button in the browser, the user can go to the previous page where he sent the details. And when the user submits this, the data will again be stored in the database. I need to prevent this behavior. (Something similar and reload the page.)
Things I've done so far: clear the browser cache. The code works fine, but not the expected result.
Sorry, I cannot share the code due to company policies. I need help to prevent this behavior or workaround.
Thanks in advance.
source
share