...

View Full Version : Slider plugin giving me trouble with click buttons/pager



sethwb
10-06-2010, 06:00 AM
Hi all I'm using a nifty jQuery slider plugin but I'm having trouble attaching the click event to my pager (slide buttons), It's the line that starts "pagerAnchorBuilder:"..

What am I doing wrong?

Plugin:
http://malsup.com/jquery/cycle/




$j('#hp_rotatingBanners').cycle({
fx: 'scrollLeft',
speed: 1000,
sync: 1,
timeout: 4000,
pager: '#hp_rotatingBanners_controls',
pagerAnchorBuilder: function(idx, slide){
return $j('#hp_rotatingBanners_controls a.pos'+slide);
},
updateActivePagerLink:function(idx, slide) {

if (slide == 0) {
$j(".pos" + slide).css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668861714&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos1").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855412&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos2").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855429&assetType=MMM_Image&blobAttribute=ImageFile")');
}
else
if (slide == 1) {
$j(".pos" + slide).css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668861737&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos0").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855403&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos2").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855429&assetType=MMM_Image&blobAttribute=ImageFile")');
}
else
if (slide == 2) {
$j(".pos" + slide).css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668861758&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos0").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855403&assetType=MMM_Image&blobAttribute=ImageFile")');
$j(".pos1").css('background-image', 'url("/3MContentRetrievalAPI/BlobServlet?assetId=1273668855412&assetType=MMM_Image&blobAttribute=ImageFile")');
}
}
});



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum