1

我这里有一些幻灯片的代码,我需要添加链接,它是一个运行良好的 JavaScript 图像数组,但我不确定如何为每张图片添加链接。

我是 JS 的新手。

var mygallery=new fadeSlideShow({
    wrapperid: "fadeshow1", //ID of blank DIV on page to house Slideshow
    dimensions: [200, 235], //width/height of gallery in pixels. Should reflect dimensions of largest image
    imagearray: [
        ["images_ads/image1.jpg"],
        ["images_ads/image2.jpg"],
        ["images_ads/image3.jpg"]
    ],
    displaymode: {type:'auto', pause:5000, cycles:0, wraparound:false},
    persist: false, //remember last viewed slide and recall within same session?
    fadeduration: 1000, //transition duration (milliseconds)
    descreveal: "ondemand",
    togglerid: ""
})
4

1 回答 1

0

根据动态驱动器,图像数组中的第二个键应该是您的 URL 值,第三个值是您要显示的文本 例如:

["images_ads/image1.jpg", "http://www.stackoverflow.com", "Your text goes here"],
于 2013-03-08T01:55:29.323 回答