PDA

View Full Version : Ultimate Fade-in Slide Show: Undefined error



odelldesign@gmail.com
11-01-2007, 01:02 PM
1) Script Title: Ultimate Fade-in Slide Show

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

3) Describe problem: Fadeshow is Undefined

I have tried different variations and gone over and over the script and studied some of the DD posts to see where I could've done something wrong. But, I just keep getting a "Fadeshow is Undefined. Source... line 385..."

Here is part of my header code:

var fadeimages=[]; //FIRST SLIDESHOW
//SET IMAGE PATHS. Extend or contract array as needed

fadeimages[0]=[
"../../images/partners/toyota/market-toyota-tokai-corolla-nov07advert-0.jpg", "http://www.toyota.co.za/models/viewrange.aspx?id=corolla" target="_blank"]
fadeimages[1]=[
"../../images/partners/toyota/market-toyota-tokai-corolla-nov07advert-1.jpg", "http://www.toyota.co.za/models/viewrange.aspx?id=corolla" target="_blank"]
fadeimages[2]=[
"../../images/partners/toyota/market-toyota-tokai-corolla-nov07advert-2.jpg", "http://www.toyota.co.za/models/viewrange.aspx?id=corolla" target="_blank"] //image with link and target syntax

var fadebgcolor="white"

etc


and my body code is:

<script type="text/javascript">
//new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
new fadeshow(fadeimages, 430, 288, 0, 3000, 1, "R")
</script>

My URL: http://www.bhs.org.za/bergvliet-high-school-files/partners/bhs-partner-market-toyota-tokai.htm

jscheuer1
11-01-2007, 01:52 PM
Get rid of all:

target=

from the array. If you look back over the instructions, you will see that it is not called for. There could also be other problems.

odelldesign@gmail.com
11-02-2007, 10:50 AM
John thanks for your help.

I changed the header line to read

var fadeimages=new Array()

and simplified the image reference in the header to read for plain image syntax. (see page source at http://www.bhs.org.za/bergvliet-high-school-files/partners/bhs-partner-market-toyota-tokai1.htm)

But, I still get this messge when I try to open the page:

"Java Script error
Description: 'fadeshow' is undefined.
Source: http://www.bhs.org.za/bergvliet-high-school-files/partners/bhs-partner-market-toyota-tokai1.htm
Line: 376"

Line 376 is: new fadeshow(fadeimages, 430, 288, 0, 3000, 1, "R")

I can't see where my mistake is, can you?

James

odelldesign@gmail.com
11-02-2007, 12:47 PM
After all that I pasted over the header code and now it works!

Thank you for being helpful and firm. It made me come up with the solution and I feel great!

jscheuer1
11-02-2007, 12:48 PM
It's working now, no error. Clear your browser's cache.