0
我如何在下面的代碼中進行這些更改?更改圖片庫功能
- 顯示縮略圖圖片標題爲
<div id="main">
當我們點擊,縮略圖。下面 - 顯示縮略圖標題爲「blank.gif」(我的意思是,當我們點擊拇指圖像,該圖像大拇指的
<div id="main">
獲取URL,也。我想進行此更改使用全<div id="main">
- 集URL縮略圖任何圖像式屏幕)
代碼在這裏:
<div id="main">
<p><img src="blank.gif" /></p>
</div>
$(".productthumbs img").click(function() {
// calclulate large image's URL based on the thumbnail URL (flickr specific)
var url = $(this).attr("src");
// get handle to element that wraps the image and make it semitransparent
var wrap = $("#main").fadeTo("medium", 0.5);
// the large image from flickr
var img = new Image();
// call this function after it's loaded
img.onload = function() {
// make wrapper fully visible
wrap.fadeTo("fast", 1);
// change the image
wrap.find("img").attr("src", url);
};
// begin loading the image from flickr
img.src = url;
// when page loads simulate a "click" on the first image
}).filter(":first").click();