PDA

View Full Version : images wont refresh


jewishj
09-06-2003, 04:44 PM
I have a script in which the user is shown all the images in a directory (the images are all in JPEG format and are in numeric order... 1.jpg, 2.jpg, and so forth). They can then add a new image to the directory (and it would be named [highest current number for imagename]+1.jpg) or choose any number of images (by checking checkboxes next to the images) and delete the selected images.

All of those parts do exactly what they are supposed to. The problem is that when they get back to the main page that shows the images in the directory, it will still show the old images.

A couple of examples to describe what I mean...

1) say you have images 1.jpg-4.jpg and decide to delete 2.jpg and 3.jpg. After doing so, the images in the directory will be the correct images, and 2.jpg and 3.jpg will be gone but on the page that displays the images it may show 1.jpg and 3.jpg or 1.jpg and 2.jpg etc.

2) say you have images 1.jpg-4.jpg and upload a new image. It will show five images.. but 5.jpg will be displayed as 4.jpg or 3.jpg etc.

NOTE: After refreshing the page all of these problems are fixed.

I've tried using every no-cache meta tag and header command I can find, and have also tried using the session_cache_expire() and session_cache_limiter() functions to no avail.

NOTE: The script is using a session to control user logins and keep track of the username, pw, id, etc.

Thanks in advance for any help