Now the problem is this : in the local version, I can select on the first page the letter "B" to get all movies starting with a B. When I select , say, "Bad Santa" in thsi list, I can see the detail screen containing the poster of the movie (a BLOB). If I go back to the list and select "the Blob" from 1958, I see the poster with the photo of Steve Mc QUeen. If I go back to the list once more, I can select "the Blob" from 1988, and I see the poster from this movie.
So locally, everything is OK. Then I published the web application on my web site, and this still keeps on working. But when I go to the office, and try to go to my web application at work, whichever poster I see first, this is the poster that will be shown on all the other detail screens. So, for instance, with the above scenarion, I see the data from "bad santa" and its poster. If I go to the blob, I see the data of the blob (title, year) but still the poster of "bad santa".
So, at work, I can only view the first poster, even though I select other movies. Can anyone tell me where the error is ?
I might be trying to shoot in the dark here, but anyway...
Have you checked it's not a caching issue? Try turning caching off and on on the browser, restarting the browser each time and maybe emptying the cache. I don't know much about your system so I can't make any better guess right now.
It could also be a session issue (shoot me if I'm wrong anyone), do you have cookies enabled at work/home? [ March 12, 2005: Message edited by: Kristian Breifossmo ]
Frankly, after reading your answer, I think it must be a cache problem. I already had this before at work with another web application. Then, the JSP's never changed. To solve this, I had to add the following lines to each JSP :
<% response.setHeader("Cache-Control","no-cache"); response.setHeader("Expires", "0"); response.setHeader("Pragma", "No-cache"); response.addHeader("Cache-control", "no-store"); // tell proxy not to cache response.addHeader("Cache-control", "max-age=0"); // stale right away %>
But now it's different. The JSP's are all right, but the image shown is made by a servlet which is called inside a JSP with the following code
the /gco/cluifimg is referred to a servlet which takes care of the translation from the blob into an array of bytes. This works fine at home, but at work, I suppose the proxyserver is only calling this servlet once, putting it into the cache, and never bother again to see if it has changed. So, I have to look for a way to prevent the caching of the output of this servlet.
i also have this problem..but instead of using servlet..mine is just printing out the filename Something like <img src="<%=request.getContexxtPath()%>/images/<%=imageFileName%>" /> where imageFileName is the fileName i took from database..but cos i can edit my picture...so the filename when edited..is the same...just that..the picture image changes...
cos when i tried toggle between .jpg and .gif file...the image changes..but when i save .jpg..the image won't change when reload..then i have to press F5 to refresh then it reload..
when i edit and save the image file name will be like 1000001.jpg so when i save to .gif it will be 1000001.gif but when i save a .jpg file..it becomes somename.jpg to 100001.jpg