Page 3 of 3 FirstFirst 123
Results 21 to 26 of 26

Thread: Ultimate Fade-in slideshow

  1. #21
    Join Date
    Dec 2005
    Posts
    8
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default Addition of Captions?

    Hi!

    I found this thread after I posted this question in another, but seems like this might be a better place for it.

    What changes to the script would I need to make if I wanted to display a caption for each image below the image itself? I saw with a search, there was an older version of the fade-in script where the caption was an additional field in the array with the image and wondered what it would take to add that to the ultimate version.

    Thanks!
    Tom

  2. #22
    Join Date
    Dec 2005
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    Quote Originally Posted by jscheuer1
    For starters, please put the credit for the script on the page where it can be seen when someone views the source.

    The reason that the links are getting messed up is that you have several slideshows on the page all using the same array of images and links. As each individual show makes its own image only array (for preloading) from this array that corresponds to the one with the links, this has defeated the ability of the script to keep each slideshow operating exclusively in a separately named code space. As each subsequent show is loaded the main array (with its links) is shuffled, disconnecting it from the previous show's image only array. You can use the same images for each show but, you need to make up a separate array containing them with a separate name for use with each slideshow.

    The script may be able to be rewritten to allow its use in the manner you have tried, but it would be much simpler to use separate arrays, If you want, you can get away with only defining the array once and then assigning it to as many unique names as you have shows, each to be used with a single show:

    Code:
    var affbuttons=new Array()
    //SET IMAGE PATHS. Extend or contract array as needed
    affbuttons[0]=["http://www.pluginexe.com/atomicfire.gif", "http://www.atomic-fire.com/", "_blank"]
    affbuttons[1]=["http://themechanicalmaniacs.com/layout/aff/affiliate5.gif", "http://www.themechanicalmaniacs.com/", "_blank"]
    affbuttons[2]=["http://www.kingdom-hearts2.com/zerov/pmm.gif", "http://www.planet-megaman.com/", "_blank"]
    affbuttons[3]=["http://plug-in.planet-megaman.com/linktobutton-20.jpg", "http://www.pluginexe.com/", "_blank"]
    affbuttons[4]=["http://www.rockmantv.com/images/8831affbutton.jpg", "http://www.rockmantv.com/", "_blank"]
    affbuttons[5]=["http://www.megaman-sprites.com/aff/sprites_inc.gif", "http://www.megaman-sprites.com/", "_blank"]
    
    affbuttons0=affbuttons1=affbutttons2=affbuttons3=affbuttons
    Use as many affbuttons# as you need. Just to be on the safe side, define all of them before creating any slideshows that use them and do not use the original affbuttons array in any of the slideshows. Assign each individual affiliate show its own numbered affbuttons# array:

    Code:
    <table class="tborder" cellpadding="6" cellspacing="0" border="0" width="100%" align="center" style="border-top-width:0px"> <tr align="center"> <td class="vbmenu_control"> <script type="text/javascript">
    //new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
    new fadeshow(affbuttons0, 88, 31, 0, 5000, 1, "R")
    </script> </td> <td class="vbmenu_control"> <script type="text/javascript">
    //new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
    new fadeshow(affbuttons1, 88, 31, 0, 5000, 1, "R")
    </script> </td> <td class="vbmenu_control"> <script type="text/javascript">
    //new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
    new fadeshow(affbuttons2, 88, 31, 0, 5000, 1, "R")
    </script> </td> <td class="vbmenu_control"> <script type="text/javascript">
    //new fadeshow(IMAGES_ARRAY_NAME, slideshow_width, slideshow_height, borderwidth, delay, pause (0=no, 1=yes), optionalRandomOrder)
    new fadeshow(affbuttons3, 88, 31, 0, 5000, 1, "R")
    </script> . . .
    i've added the script credit to the actual page (it was in the js file before, now its there AND in the page source)

    i tried the fix you said there, it didnt seem to work, the slideshows still display, but i have the same problem with the links

  3. #23
    Join Date
    Mar 2005
    Location
    SE PA USA
    Posts
    30,495
    Thanks
    82
    Thanked 3,449 Times in 3,410 Posts
    Blog Entries
    12

    Default

    That's what I get for not testing this one out, it appears that this type of syntax is required (example taken from the demo) to define the arrays:

    Code:
    var fadeimages=new Array()
    //SET IMAGE PATHS. Extend or contract array as needed
    fadeimages[0]=["photo1.jpg", "", ""] //plain image syntax
    fadeimages[1]=["photo2.jpg", "http://www.cssdrive.com", ""] //image with link syntax
    fadeimages[2]=["photo3.jpg", "http://www.javascriptkit.com", "_new"] //image with link and target syntax
    
    var faders=['fadei0', 'fadei1', 'fadei2', 'fadei3']
    
    for (var i_tem = 0; i_tem < faders.length; i_tem++)
    faders[i_tem]=new Array();
    
    for (i_tem = 0; i_tem < fadeimages.length; i_tem++)
    faders[0][i_tem]=faders[1][i_tem]=faders[2][i_tem]=faders[3][i_tem]=fadeimages[i_tem]
    Then to use them in individual shows:

    Code:
    new fadeshow(faders[0], 140, 255, 0, 3000, 1, "R")
    new fadeshow(faders[1], 140, 255, 0, 3000, 1, "R")
    new fadeshow(faders[2], 140, 255, 0, 3000, 1, "R")
    new fadeshow(faders[3], 140, 255, 0, 3000, 1, "R")
    - John
    ________________________

    Show Additional Thanks: International Rescue Committee - Donate or: The Ocean Conservancy - Donate or: PayPal - Donate

  4. #24
    Join Date
    Dec 2005
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Default

    that seems to have done the trick, although that's a lot more complex than i would have guessed it needed to be
    but none the less thank you, im getting a stronger grip on javascript as well (im a php coder so it's pretty similar)

  5. #25
    Join Date
    Jan 2006
    Posts
    5
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Smile Can't get three session of images to work

    Hi all. First, I goofed on my registration, so I would ask that you delete user "rscptt7706". Sorry for the inconvenience.

    Here is a link top a page that I am trying without success to load three sessions of the fadein's. I know I am probably missing an obvious step, but I have been over it several (numerous) times and can't find the glitch.

    Could you look at it for me??

    Thanks so much!!

    fadeinslideshow3b


    RScott7706

  6. #26
    Join Date
    Aug 2004
    Posts
    10,143
    Thanks
    3
    Thanked 1,008 Times in 993 Posts
    Blog Entries
    16

    Default

    rscptt7706, the third one is being displayed- just scroll down your page to see it. You probably will want to increase the height of the slideshow, as it's being clipped right now.

    With that said, I'm going to close this thread, as it was originally meant just to report bugs. The correct forum to post for help/support on a script is here.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •