Topic: First image not pre-loading when firstImageIndex is invoked

Greetings all,
    I have a simpleviewer pro 2.0.1 gallery embedded into a .php page.  I just modified the code of my .php page so that I can use firstImageIndex to link directly to images in the gallery.  I am using php to GET a query string variable called "id" which I am passing to flashvar.firstImageIndex like this:

<?php
//set $id 's value to whatever is contained on the url.
$id = $_GET['id'];
?>

flashvars.firstImageIndex = <?echo("$id")?>;

For example, if I add ?id=4 onto my url, the gallery starts at image index 4.  This part works perfectly. 

There is one big hitch though: whenever I load the page using any index other than 0, the very first image and thumbnail in the gallery do not preload.  In this case, you can only view this image by going to the second image in the gallery and clicking the "previous image" button.


If I use ?id=0, the first image loads just fine.  If I use ?id=anything else, the first image/thumbnail simply does not show up!  Anyone know what could be causing my bug?

Here are direct links to my pages.  The first shows what how the image shows up when ?id=0.  The second shows how the image does not appear when ?id is not 0.

http://www.joshuacripps.com/galleries/t … s.php?id=0 

http://www.joshuacripps.com/galleries/t … s.php?id=1

And my full simpleviewer head:

<!-- SIMPLEVIEWER HEAD. Paste this into the head of the HTML page-->
<?php
//set $id 's value to whatever is contained on the url.
$id = $_GET['id'];
?>

<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/swfobject/2.2/swfobject.js"></script>


<script type="text/javascript">

var flashvars = {};
flashvars.galleryURL = "gallery.xml";
flashvars.firstImageIndex = <?echo("$id")?>;
var params = {};
params.bgcolor = "000000";
params.allowfullscreen = true;
params.allowscriptaccess = "always";
swfobject.embedSWF("simpleviewer.swf", "flashContent", "779", "470", "9.0.124", false, flashvars, params);

</script>

Any help on this would be greatly appreciated.  Thanks all!

Josh

Re: First image not pre-loading when firstImageIndex is invoked

Bump.  Any coders out there know what could be causing this issue?

Thanks,

Josh

Re: First image not pre-loading when firstImageIndex is invoked

Hi,

looks like you have found a bug. Setting 'thumbPreloading' to 'PAGE' should fix the issue. This bug will be fixed in the next version.

Felix Turner
SimpleViewer Support Team.

Re: First image not pre-loading when firstImageIndex is invoked

Yeah, I tried that, to no avail.  Thanks for looking into this!

Josh

Re: First image not pre-loading when firstImageIndex is invoked

Are you sure? It worked here.

Felix Turner
SimpleViewer Support Team.

Re: First image not pre-loading when firstImageIndex is invoked

Thanks Felix.  Yes, it did work.  I originally misread what you typed and set 'imagepreloading' to 'page', not 'thumbpreloading'.

Cheers!

Josh