Hi, I have a JSP page which uses a bean to retrieve some prices and these prices are formatted as a currency using the JSTL formatNumber:
This works fine on my local machine for as many times I call the page. However, when I uploed the very same page to the server, it always displays the same value for all double entries. Say, if the salary entered was 50000 the first time, it always sticks to that value (for all prices) until the app / tomcat is restarted. Can someone point out my error? Note: I need the page to take part in the session as only validated users should be accessing the page. Thanks in advance - FK -
The secret to creativity is knowing how to hide your sources.
posted 12 years ago
I don't think your code is in error. What is far more likely is that someone, somewhere, is caching the first response and giving you that whenever you request the page. Set the page to expire immediately at all levels (metatags, HTTP headers, and is you can server configuration). It's no guarantee but better than nothing.