Thumbnails Out of Order on Reload of Page
Hi -
I managed to integrate a gallery into my site using code provided here:
Fresh Sliding Thumbnails Gallery with JQuery and PHP
However, I noticed that even with their demo site (here), the thumbnails sometime come in out of order on the page when you hit the reload page button on the browser repeatedly.
Based on what I read, the gallery relies on thumbs.php to create a JSON string with all the elements for the thumbnails.
In the JavaScript (jquery.gallery.js), a buildThumbs() function gets the JSON object and builds the HTML elements that displays the thumbnail gallery, which when clicked will display the main image for the thumbnail.
I tried to check to see if maybe thumbs.php was not sorting properly but it was, and the JSON string looks correct and in order by file name.
Can someone shed some light as to why the thumbnails come in out of order on a page reload? And how would I go about ensuring that the order of the thumbnails load in the same order every time?
Thanks