Dear Experts
I am new to blogging and trying to make my Food Blog more interesting for the readers! I am really a novice at HTML.
I saw these cool slide shows on many food blogs and wanted to try this out.
Unfortunately...I do not know what has gone wrong!!!
MUCH APPRECIATE YOUR HELP!!! Please let me know how do I make this Conveyor Belt work smoothly!! TIA!!
My TEST PAGE is -- > http://meenasvegcorner.blogspot.in/
The HTML Script I added as a widget is -- >
<div class="widget HTML" id="HTML5">
<div class="widget-content">
<script type="text/javascript">
/***********************************************
* Conveyor belt slideshow script- © Dynamic Drive DHTML code library (www.dynamicdrive.com)
* This notice MUST stay intact for legal use
* Visit Dynamic Drive at http://www.dynamicdrive.com/ for full source code
***********************************************/
//Specify the slider's width (in pixels)
var sliderwidth="535px"
//Specify the slider's height
var sliderheight="120px"
//Specify the slider's slide speed (larger is faster 1-10)
var slidespeed=3
//configure background color:
slidebgcolor="#EAEAEA"
//Specify the slider's images
var leftrightslide=new Array()
var finalslide=''
leftrightslide[1]='<a href="http://meenastastemantra.blogspot.in/2014/12/chakkaravallikizhangu-murukku-sweet.html" target="_blank"><img title="Sweet Potato Murukku" alt="Sweet Potato Murukku" src="http://1.bp.blogspot.com/-QWmhc1axN0g/VIqIPMgyOoI/AAAAAAAAATg/5L6OUvQjn2Q/s1600/Sweet%2BPotato%2BMurukku.jpg" width="120" height="120" border=1></a>'
leftrightslide[2]='<a href="http://meenastastemantra.blogspot.in/2015/10/cornflakes-chivda-easy-to-make-snack.html" target="_blank"><img title="Cornflakes Chivda Cornflakes Mixture" alt="Sweet Potato Murukku" src="http://4.bp.blogspot.com/-e5dIifImYEw/ViTdkMWg29I/AAAAAAAAFw8/wLe2xQh-_LQ/s1600/20151019_165228.jpg" width="120" height="120" border=1></a>'
var rightleftslide=new Array()
rightleftslide[1]='<a href="http://meenastastemantra.blogspot.in/2014/12/chakkaravallikizhangu-murukku-sweet.html" target="_blank"><img title="Sweet Potato Murukku" alt="Sweet Potato Murukku" src="http://1.bp.blogspot.com/-QWmhc1axN0g/VIqIPMgyOoI/AAAAAAAAATg/5L6OUvQjn2Q/s1600/Sweet%2BPotato%2BMurukku.jpg" width="120" height="120" border=1></a>'
rightleftslide[2]='<a href="http://meenastastemantra.blogspot.in/2015/10/cornflakes-chivda-easy-to-make-snack.html" target="_blank"><img title="Cornflakes Chivda Cornflakes Mixture" alt="Sweet Potato Murukku" src="http://4.bp.blogspot.com/-e5dIifImYEw/ViTdkMWg29I/AAAAAAAAFw8/wLe2xQh-_LQ/s1600/20151019_165228.jpg" width="120" height="120" border=1></a>'
//Specify gap between each image (use HTML):
var imagegap=" "
//Specify pixels gap between each slideshow rotation (use integer):
var slideshowgap=3
////NO NEED TO EDIT BELOW THIS LINE////////////
var copyspeed=slidespeed
var copyspeed1=slidespeed
leftrightslide='<nobr>'+leftrightslide.join(imagegap)+'</nobr>'
rightleftslide='<nobr>'+rightleftslide.join(imagegap)+'</nobr>'
var iedom=document.all||document.getElementById
if (iedom){
document.write('<span id="SlideTemp1" style="visibility:hidden;position:absolute;top:-100px;left:-9000px">'+leftrightslide+'</span>')
document.write('<span id="SlideTemp2" style="visibility:hidden;position:absolute;top:100px;right:9000px">'+rightleftslide+'</span>')
}
var actualwidth=''
var actualwidth1=''
var cross_slide, ns_slide
function fillup(){
if (iedom){
cross_slide=document.getElementById? document.getElementById("SlideTest2") : document.all.SlideTest2
cross_slide2=document.getElementById? document.getElementById("SlideTest3") : document.all.SlideTest3
cross_slide.innerHTML=cross_slide2.innerHTML=leftrightslide
actualwidth=document.all? cross_slide.offsetWidth : document.getElementById("SlideTemp1").offsetWidth
cross_slide2.style.left=actualwidth+slideshowgap+"px"
cross_slide4=document.getElementById? document.getElementById("SlideTest4") : document.all.SlideTest4
cross_slide5=document.getElementById? document.getElementById("SlideTest5") : document.all.SlideTest5
cross_slide4.innerHTML=cross_slide5.innerHTML=rightleftslide
actualwidth1=document.all? cross_slide4.offsetWidth : document.getElementById("SlideTemp2").offsetWidth
cross_slide5.style.right=actualwidth1+slideshowgap+"px"
}
else if (document.layers){
ns_slide=document.ns_slidemenu.document.ns_slidemenu2
ns_slide2=document.ns_slidemenu.document.ns_slidemenu3
ns_slide.document.write(leftrightslide)
ns_slide.document.close()
actualwidth=ns_slide.document.width
ns_slide2.left=actualwidth+slideshowgap
ns_slide2.document.write(leftrightslide)
ns_slide2.document.close()
}
lefttime=setInterval("slideleft()",30)
righttime=setInterval("slideright()",30)
}
window.onload=fillup
function slideleft(){
if (iedom){
if (parseInt(cross_slide.style.left)>(actualwidth*(-1)+8))
cross_slide.style.left=parseInt(cross_slide.style.left)-copyspeed+"px"
else
cross_slide.style.left=parseInt(cross_slide2.style.left)+actualwidth+slideshowgap+"px"
if (parseInt(cross_slide2.style.left)>(actualwidth*(-1)+8))
cross_slide2.style.left=parseInt(cross_slide2.style.left)-copyspeed+"px"
else
cross_slide2.style.left=parseInt(cross_slide.style.left)+actualwidth+slideshowgap+"px"
}
else if (document.layers){
if (ns_slide.left>(actualwidth*(-1)+8))
ns_slide.left-=copyspeed
else
ns_slide.left=ns_slide2.left+actualwidth+slideshowgap
if (ns_slide2.left>(actualwidth*(-1)+8))
ns_slide2.left-=copyspeed
else
ns_slide2.left=ns_slide.left+actualwidth+slideshowgap
}
}
function slideright(){
if (iedom){
if (parseInt(cross_slide4.style.right)>(actualwidth1*(-1)+8))
cross_slide4.style.right=parseInt(cross_slide4.style.right)-copyspeed1+"px"
else
cross_slide4.style.right=parseInt(cross_slide5.style.right)+actualwidth1+slideshowgap+"px"
if (parseInt(cross_slide5.style.right)>(actualwidth1*(-1)+8))
cross_slide5.style.right=parseInt(cross_slide5.style.right)-copyspeed1+"px"
else
cross_slide5.style.right=parseInt(cross_slide4.style.right)+actualwidth1+slideshowgap+"px"
}
}
if (iedom||document.layers){
with (document){
document.write('<table border="0" cellspacing="0" cellpadding="0"> <tr><td align="center"> <b> Diwali Savouries</b> </td> <td> </td> <td align="center"><b>Diwali Sweets </b></td></tr> <tr><td>')
if (iedom){
write('<div style="position:relative;width:'+sliderwidth+';height:'+sliderheight+';overflow:hidden">')
write('<div style="position:absolute;width:'+sliderwidth+';height:'+sliderheight+';background-color:'+slidebgcolor+'" onMouseover="copyspeed=0" onMouseout="copyspeed=slidespeed">')
write('<div id="SlideTest2" style="position:absolute;left:0px;top:0px"></div>')
write('<div id="SlideTest3" style="position:absolute;left:-1000px;top:0px"></div>')
write('</div></div>')
document.write('</td> <td> </td><td>')
write('<div id="t1" style="position:relative;width:'+sliderwidth+';height:'+sliderheight+';overflow:hidden">')
write('<div id="t2" style="position:absolute;width:'+sliderwidth+';height:'+sliderheight+';background-color:'+slidebgcolor+'" onMouseover="copyspeed1=0" onMouseout="copyspeed1=slidespeed">')
write('<div id="SlideTest4" style="position:absolute;right:0px;top:0px"></div>')
write('<div id="SlideTest5" style="position:absolute;right:1000px;top:0px"></div>')
write('</div></div>')
}
else if (document.layers){
write('<ilayer width='+sliderwidth+' height='+sliderheight+' name="ns_slidemenu" bgColor='+slidebgcolor+'>')
write('<layer name="ns_slidemenu2" left=0 top=0 onMouseover="copyspeed=0" onMouseout="copyspeed=slidespeed"></layer>')
write('<layer name="ns_slidemenu3" left=0 top=0 onMouseover="copyspeed=0" onMouseout="copyspeed=slidespeed"></layer>')
write('</ilayer>')
}
document.write('</td> </tr> </table>')
}
}
</script>
<span id="SlideTemp1" style="visibility:hidden;position:absolute;top:-100px;left:-9000px"><nobr>
<script type="text/javascript">
var __fbr_pid = "80529";
var __fbr_bid = "23064";
var __fbr_sid = "65729";
var __fbr_size = "728x90";
var __fbr_auid = "314658";
var __fbr_zone = "";
</script></nobr></span></div></div>
is the slideshow what i get to if i click hkhdfwkd? looks like the urls to the images are wrong. check that.
ok. and the problem is it shows the same image allthe time instead of different images i gather. i'll have a look. i'll also move the thead to the js forum.
fact is that the code you posted does what i think it should. so does the script at your site if i copy it and run it on its own. so it must be something else in that page that interferes. problem is there's 4997 lines of else...
And, there are two sliders on that page. You can't use that one script to serve them both. Changes need to be made to distinguish the two sliders from each other.
Besides, I get 18 js errors. The page also has HTML errors (validate at https://validator.w3.org/nu/ ) and check the CSS too at http://jigsaw.w3.org/css-validator/ .
Although the domain stays with ".in", I do get a cookie message in my own language.
hmm. i assumed the script was written for two slides. and it actually works when taken out of the page.
Yeah, maybe. I didn't look that well. Though on the demo page at dynamicdrive, there's only one slider: http://www.dynamicdrive.com/dynamicindex14/leftrightslide.htm .
Remains that there are errors. And the image in the right slide shakes.
I'm just wondering, but how is this SS Scripting, it seems to be all Client Side Javascript.
trtue. didn't notice. thanks.
Powered by Invision Power Board (http://www.invisionboard.com)
© Invision Power Services (http://www.invisionpower.com)