You use a function nextPicture() to switch to, well, the next picture. Other than your statement above, I believe it is being downloaded from allmusic and looks like this:
Code: -------------------- function setPicture(i) { var NewPictureURL = 'http://image.allmusic.com/00/amg/pic200/dr' + Pictures[i].substr(0,2) + '00/' + Pictures[i].substr(0,4) + '/' + Pictures[i] + '.jpg'; document.getElementById('Picture').src = NewPictureURL; if(Credits[i]) { var NewPictureCredits = 'Photo by <span>' + Credits[i] + '</span>'; document.getElementById('PictureCredits').style.visibility = "visible"; document.getElementById('PictureCredits').innerHTML = NewPictureCredits; } else { document.getElementById('PictureCredits').style.visibility = "hidden"; } } function nextPicture() { i++; if ( i > Pictures.length -1 ) { i = 0; } setPicture(i); } -------------------- Also, you define some local variables in Code: -------------------- <script type="text/javascript" language="javascript"> <!-- Pictures = new Array("P07306C7I6A","P20747Y0NF1","P19174BHF5V","P07309PWJ81","P07308CNGV3","P07307V5VRJ","P03725T3746","P03724V8039"); Credits = new Array("","Marina Chavez","Anton Corbijn","Kevin Westenberg","","Anton Corbijn","Anton Corbijn","Anton Corbijn"); var i = 2; var x = 8; --> </script> -------------------- If this code is loaded through an Ajax Call it will not be available on a global context, so the link href="javascript:nextPicture()" will not succeed. What you could do, for example, is wrap the code into something like Code: -------------------- <script type="text/javascript" language="javascript" src="http://www.allmusic.com/js/pictures.js"></script> <script> extNextPicture = function() { nextPicture() } </script> -------------------- I'm not sure, maybe there's a shorter version for this (like extNextPicture = nextPicture). If you then use extNextPicture in the link, it should work in the iPeng page as well... Hey, You are doing all this JavaScript stuff on the new skin, I think you know more about JS than I do... -- pippin --- see iPeng at penguinlovesmusic.com ------------------------------------------------------------------------ pippin's Profile: http://forums.slimdevices.com/member.php?userid=13777 View this thread: http://forums.slimdevices.com/showthread.php?t=43713 _______________________________________________ plugins mailing list plugins@lists.slimdevices.com http://lists.slimdevices.com/lists/listinfo/plugins