PDA

View Full Version : Ultimate Fade-in Slideshow - wont work on-line but will work off-line



southerncrow
12-21-2010, 04:02 AM
1) Script Title: Ultimate Fade-In Slideshow

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

3) Describe problem: Hello......When I upload the files to the host server the slideshow refuses to work, however it will work off-line when i'm playing with it on my computer. Website is tasmaniashop.com.au


.....many thanks.

Nile
12-21-2010, 04:08 AM
Images dont exist.


["SlideshowFiles/tasmania/1.jpg", "", "", ""],
["SlideshowFiles/tasmania/2.jpg", "", "", ""],
["SlideshowFiles/tasmania/3.jpg", "", "", ""],
["SlideshowFiles/tasmania/5.jpg", "", "", ""],
["SlideshowFiles/tasmania/6.jpg", "", "", ""],
["SlideshowFiles/tasmania/7.jpg", "", "", ""],
["SlideshowFiles/tasmania/10.jpg", "", "", ""],
["SlideshowFiles/tasmania/11.jpg", "", "", ""],
["SlideshowFiles/tasmania/17.jpg", "", "", ""],
["SlideshowFiles/tasmania/21.jpg", "", "", ""],
["SlideshowFiles/tasmania/23.jpg", "", "", ""],
["SlideshowFiles/tasmania/25.jpg", "", "", ""],
["SlideshowFiles/tasmania/27.jpg", "", "", ""],
["SlideshowFiles/tasmania/30.jpg", "", "", ""],
["SlideshowFiles/tasmania/35.jpg", "", "", ""],
["SlideshowFiles/tasmania/36.jpg", "", "", ""],
["SlideshowFiles/tasmania/37.jpg", "", "", ""],
["SlideshowFiles/tasmania/38.jpg", "", "", ""],
["SlideshowFiles/tasmania/39.jpg", "", "", ""],
["SlideshowFiles/tasmania/40.jpg", "", "", ""]

jscheuer1
12-21-2010, 05:53 AM
That's not entirely true Nile. But it's the right idea and most of those are 404 Not Found. The number 3, 21, 23, 27, 36, 38 images are there. But since the number 1 image is not, the slideshow never initializes.

And to go into more detail in this specific situation, all of the images are sort of there. It's just a difference in upper and lower case letters used in their extensions (.jpg vs .JPG) that make the ones that are 404 Not Found inaccessible. Upper and lower case paths, filenames and extensions almost always matter on the server, almost never on the local machine. This is made even more confusing at times because in folder views often the local machine doesn't display the actual case of paths, filenames, and/or extensions. Sometimes it doesn't even display the extension at all.

Anyways, if you rewrite the image array like so:


<script type="text/javascript">
var mygallery=new fadeSlideShow({
wrapperid: "fadeshow1", //ID of blank DIV on page to house Slideshow
dimensions: [500, 375], //width/height of gallery in pixels. Should reflect dimensions of largest image
imagearray: [
["SlideShowFiles/tasmania/1.JPG", "", "", ""],
["SlideShowFiles/tasmania/2.JPG", "", "", ""],
["SlideShowFiles/tasmania/3.jpg", "", "", ""],
["SlideShowFiles/tasmania/5.JPG", "", "", ""],
["SlideShowFiles/tasmania/6.JPG", "", "", ""],
["SlideShowFiles/tasmania/7.JPG", "", "", ""],
["SlideShowFiles/tasmania/10.JPG", "", "", ""],
["SlideShowFiles/tasmania/11.JPG", "", "", ""],
["SlideShowFiles/tasmania/17.JPG", "", "", ""],
["SlideShowFiles/tasmania/21.jpg", "", "", ""],
["SlideShowFiles/tasmania/23.jpg", "", "", ""],
["SlideShowFiles/tasmania/25.JPG", "", "", ""],
["SlideShowFiles/tasmania/27.jpg", "", "", ""],
["SlideShowFiles/tasmania/30.JPG", "", "", ""],
["SlideShowFiles/tasmania/35.JPG", "", "", ""],
["SlideShowFiles/tasmania/36.jpg", "", "", ""],
["SlideShowFiles/tasmania/37.JPG", "", "", ""],
["SlideShowFiles/tasmania/38.jpg", "", "", ""],
["SlideShowFiles/tasmania/39.JPG", "", "", ""],
["SlideShowFiles/tasmania/40.JPG", "", "", ""] //<--no trailing comma after very last image element!
],
displaymode: {type:'auto', pause:2500, cycles:0, wraparound:false},
persist: false, //remember last viewed slide and recall within same session?
fadeduration: 500, //transition duration (milliseconds)
descreveal: "ondemand",
togglerid: ""
})
</script>

All images will be present and accounted for and the slideshow will work.

southerncrow
12-21-2010, 06:42 AM
Hmm, interesting problem. I used the same digital camera for all those shots.

.....thanks for that John.

jscheuer1
12-21-2010, 07:43 AM
Differences can arise when copying, editing, optimizing and/or uploading. It all depends upon the software used for each operation, and upon how said software is used for each operation.

djr33
12-21-2010, 08:06 AM
As a general note, cameras (for whatever reason) tend to use .JPG and software programs on the computer tend to use .jpg. In fact, the only time I've ever seen .JPG show up regularly is from digital cameras.

jscheuer1
12-21-2010, 02:27 PM
As a general note, cameras (for whatever reason) tend to use .JPG and software programs on the computer tend to use .jpg. In fact, the only time I've ever seen .JPG show up regularly is from digital cameras.

That is a good general rule. But .JPG may be preserved (depending upon the considerations I've already mentioned) in other programs without showing up as .JPG in some folder views, where it may show up erroneously as .jpg or be hidden from view.

And, as you say "As a general note" - this means that some software might default to .JPG as opposed to .jpg for the extension.

It could take a lot of hunting to determine the exact sequence of events that led to the extension's being upper or lower case. For something you did before, you might never be able to retrace the steps exactly. You can always look at a directory listing in a DOS box or equivalent (like among other things a directory listing on the server if permitted) to see the actual extension used. A little trial and error should allow you to determine the easiest method(s) for doing so. There are also methods for converting to all lower case. Generally, when designing a site, everything relating to paths, filenames and extensions should be kept and/or converted to all lower case. In some situations this is overkill, in others it's the only easy method to keep what's what straight.