View Full Version : Shockwave 3D slideshow v0.9 -- Images not displaying in proper order

11-07-2013, 10:34 AM
1) Script Title: Shockwave 3D slideshow v0.9

2) Script URL (on DD): http://www.dynamicdrive.com/dynamicindex14/shockwave/index.htm

3) Describe problem: When I enter the image names into the code and then pull up the webpage, the images stay somewhat in proper order but some skip around. How can I get them to play in an exact order? For example, in the code, I put them in order of image1, image2, image3, image4, image5, image6, image7, etc., and that is the order in which I want them to display. However, every time the page loads it displays them as image1, image 2, image 3, image6, image 4, image5, image7....kind of mixed up.

Please help. Thanks! :-)

11-07-2013, 02:25 PM
The demo page appears to exhibit the same type of behavior. The quickest solution would be to change the order of the images in the imagesDataArray so that they come out the way you want.

11-07-2013, 10:16 PM
I guess I am not understanding what you mean. In the data array, I have them listed in the exact order I want them to appear. I would say roughly 90% of the images appear in the order they are supposed to but about 10% of them randomly insert themselves. This is a problem because I need all photos of the one item to show in sequential order, then all photos of the next item, etc. I have them listed that way, but they do not appear that way, and I don't think they always appear in the same wrong order, either. It is random.

10-10-2014, 11:50 PM
A year later, and I still cannot get these images to go in the proper order, even though I have them in the proper order in the ImagesDataArray. Any ideas, PLEASE?

10-11-2014, 05:16 AM
Obviously, since putting them in the order you want doesn't work, you need to do something different than that, use a different order - hoping it will come out the way you want.

Keep changing (experimenting with) their order in the array (using trial and error) until they display in the order that you desire.

10-11-2014, 06:06 AM
Okay, thanks. I had tried that but it was still random. I was just hoping there was a magic fix. Looking at this more, I think that the problem is that first time it runs through, it loads them in any order, but the next time it goes in order. I should probably pre-load the images with a script. I have this on my home page, though, so there is really no place to put a pre-loader script, right?

10-11-2014, 02:49 PM
Mmmm, I've dealt with a number of these DD slideshow scripts. Generally the loading order is not random unless specified to be so. I see nowhere in the code where there's even an option for that. Preloading the images might help. That's easy enough to test though. Simply run the slideshow until you have seen each image at least once (that means they're cached in the browser). Then hit the refresh button on the browser (soft reload, do not clear the cache), notice the order after the soft reload, that is the result you would get from a properly achieved preload. Do the soft refresh a number of times to make sure it's not also random. If all works as expected/desired, a preload should take care of it. If you need any help working that out (a proper preload), just let me know.

10-11-2014, 03:52 PM
Just tried it (soft reload simulation of preload). It doesn't seem to work. Things still come in a different order from time to time even with the images cached. I also looked through the script file, and see no way of enforcing a display order. I can't even tell (yet - though I may never be able to figure it out) how the order of the images get changed. Even if I figure that out, there may be no easy way to prevent it. Sorry. I will keep looking for a bit though.

10-11-2014, 05:27 PM
OK, I have it figured out - in theory. I think it shouldn't be too hard to make a proper fix, I have a working hack already. I'll post back with a solution later.

10-11-2014, 05:59 PM
Alright, I have it all fixed up. Well the script still sets cookies, so that if the slideshow is stopped on a particular image, it will start on that image again the next time. But the order of images will now always be that as set in the imagesDataArray. Use this modified version of the script (right click and save as):


10-13-2014, 07:45 AM
Hey! I didn't check back here until today. Thanks for your replies and the fix. It works beautifully now! I don't know what you did, but that's okay! You are one intelligent man, and I thank you for helping me! :-)