• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

JSTL formatting issue

 
Ranch Hand
Posts: 285
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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 -
 
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic