mam skrypt slideshow ( http://www.dynamicdrive.com/dynamicindex14...lucentslide.htm ) z dynamicdrive i chcialbym go lekko zmodyfikowac - chcialbym zeby fotki pojawialy sie wjezdzajac z prawej a nie z lewej strony tak jak jest teraz.

bardzo prosze o pomoc:)

  1. <script type="text/javascript">
  2.  
  3. /***********************************************
  4. * Translucent Slideshow script- Š Dynamic Drive DHTML code library (www.dynamicdrive.com)
  5. * This notice MUST stay intact for legal use
  6. * Visit Dynamic Drive at <a href="http://www.dynamicdrive.com/" target="_blank">http://www.dynamicdrive.com/</a> for full source code
  7. ***********************************************/
  8.  
  9. var trans_width='140px' //slideshow width
  10. var trans_height='225px' //slideshow height
  11. var pause=3000 //SET PAUSE BETWEEN SLIDE (3000=3 seconds)
  12. var degree=10 //animation speed. Greater is faster.
  13.  
  14. var slideshowcontent=new Array()
  15. //Define slideshow contents: [image URL, OPTIONAL LINK, OPTIONAL LINK TARGET]
  16. slideshowcontent[0]=["photo1.jpg", "http://www.cnn.com", "_new"]
  17. slideshowcontent[1]=["photo2.jpg", "", ""]
  18. slideshowcontent[2]=["photo3.jpg", "http://www.google.com", ""]
  19.  
  20.  
  21. ////NO need to edit beyond here/////////////
  22.  
  23. var bgcolor='white'
  24.  
  25. var imageholder=new Array()
  26. for (i=0;i<slideshowcontent.length;i++){
  27. imageholder[i]=new Image()
  28. imageholder[i].src=slideshowcontent[i][0]
  29. }
  30.  
  31. var ie4=document.all
  32. var dom=document.getElementById&&navigator.userAgent.indexOf("Opera")==-1
  33.  
  34. if (ie4||dom)
  35. document.write('<div style="position:relative;width:'+trans_width+';height:'+trans_height+';overflow:hidden"><div id="canvas0" style="position:absolute;background-color:'+bgcolor+';width:'+trans_width+';height:'+trans_height+';left:-'+trans_width+';filter:alpha(opacity=20);-moz-opacity:0.2;"></div><div id="canvas1" style="position:absolute;background-color:'+bgcolor+';width:'+trans_width+';height:'+trans_height+';left:-'+trans_width+';filter:alpha(opacity=20);-moz-opacity:0.2;"></div></div>')
  36. else if (document.layers){
  37. document.write('<ilayer id=tickernsmain visibility=hide width='+trans_width+' height='+trans_height+' bgColor='+bgcolor+'><layer id=tickernssub width='+trans_width+' height='+trans_height+' left=0 top=0>'+'<img src="'+slideshowcontent[0][0]+'"></layer></ilayer>')
  38. }
  39.  
  40. var curpos=trans_width*(-1)
  41. var curcanvas="canvas0"
  42. var curindex=0
  43. var nextindex=1
  44.  
  45. function getslidehtml(theslide){
  46. var slidehtml=""
  47. if (theslide[1]!="")
  48. slidehtml='<a href="'+theslide[1]+'" target="'+theslide[2]+'">'
  49. slidehtml+='<img src="'+theslide[0]+'" border="0">'
  50. if (theslide[1]!="")
  51. slidehtml+='</a>'
  52. return slidehtml
  53. }
  54.  
  55. function moveslide(){
  56. if (curpos<0){
  57. curpos=Math.min(curpos+degree,0)
  58. tempobj.style.left=curpos+"px"
  59. }
  60. else{
  61. clearInterval(dropslide)
  62. if (crossobj.filters)
  63. crossobj.filters.alpha.opacity=100
  64. else if (crossobj.style.MozOpacity)
  65. crossobj.style.MozOpacity=1
  66. nextcanvas=(curcanvas=="canvas0")? "canvas0" : "canvas1"
  67. tempobj=ie4? eval("document.all."+nextcanvas) : document.getElementById(nextcanvas)
  68. tempobj.innerHTML=getslidehtml(slideshowcontent[curindex])
  69. nextindex=(nextindex<slideshowcontent.length-1)? nextindex+1 : 0
  70. setTimeout("rotateslide()",pause)
  71. }
  72. }
  73.  
  74. function rotateslide(){
  75. if (ie4||dom){
  76. resetit(curcanvas)
  77. crossobj=tempobj=ie4? eval("document.all."+curcanvas) : document.getElementById(curcanvas)
  78. crossobj.style.zIndex++
  79. if (crossobj.filters)
  80. document.all.canvas0.filters.alpha.opacity=document.all.canvas1.filters.alpha.opacity=20
  81. else if (crossobj.style.MozOpacity)
  82. document.getElementById("canvas0").style.MozOpacity=document.getElementById("canvas1").style.MozOpacity=0.2
  83. var temp='setInterval("moveslide()",50)'
  84. dropslide=eval(temp)
  85. curcanvas=(curcanvas=="canvas0")? "canvas1" : "canvas0"
  86. }
  87. else if (document.layers){
  88. crossobj.document.write(getslidehtml(slideshowcontent[curindex]))
  89. crossobj.document.close()
  90. }
  91. curindex=(curindex<slideshowcontent.length-1)? curindex+1 : 0
  92. }
  93.  
  94. function jumptoslide(which){
  95. curindex=which
  96. rotateslide()
  97. }
  98.  
  99. function resetit(what){
  100. curpos=parseInt(trans_width)*(-1)
  101. var crossobj=ie4? eval("document.all."+what) : document.getElementById(what)
  102. crossobj.style.left=curpos+"px"
  103. }
  104.  
  105. function startit(){
  106. crossobj=ie4? eval("document.all."+curcanvas) : dom? document.getElementById(curcanvas) : document.tickernsmain.document.tickernssub
  107. if (ie4||dom){
  108. crossobj.innerHTML=getslidehtml(slideshowcontent[curindex])
  109. rotateslide()
  110. }
  111. else{
  112. document.tickernsmain.visibility='show'
  113. curindex++
  114. setInterval("rotateslide()",pause)
  115. }
  116. }
  117.  
  118. if (window.addEventListener)
  119. window.addEventListener("load", startit, false)
  120. else if (window.attachEvent)
  121. window.attachEvent("onload", startit)
  122. else if (ie4||dom||document.layers)
  123. window.onload=startit
  124.  
  125. </script>
  126.  
  127. <p align="center"><font face="arial" size="-2">This free script provided by</font><br>
  128. <font face="arial, helvetica" size="-2"><a href="http://www.dynamicdrive.com">Dynamic Drive</a></font></p>