Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
  1. #1
    New Coder
    Join Date
    Mar 2005
    Posts
    39
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Slideshow browser compatable

    Hello

    I have adapted a slideshow script for my web page Which works in all browsers (i think) but only fades in IE 6. Does anybody know of a way to make it fade in Netscape?

    Thankyou

    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
    "http://www.w3.org/TR/html4/loose.dtd">
    <html>
    <head>

    <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

    <title>PORTFOLIO</title>

    <link href="port2.css" rel="stylesheet" type="text/css">
    <link href="roll4.css" rel="stylesheet" type="text/css">

    <script language="javascript" type="text/javascript">

    var SlideShowSpeed = 3000;
    var CrossFadeDuration = 2;
    var picture = new Array();
    var caption = new Array();
    var links = new Array();

    picture[0] = "pic/bcn2.jpg";
    picture[1] = "pic/bcn1b.jpg";
    picture[2] = "pic/bcn3.jpg";
    picture[3] = "pic/bcn4.jpg";

    caption[0] = "pic/btn1.gif";
    caption[1] = "pic/btn2.gif";
    caption[2] = "pic/btn3.gif";
    caption[3] = "pic/btn4.gif";

    links[0] = "#";
    links[1] = "javascript:doImagePopUp1()";
    links[2] = "http://www.google.com";
    links[3] = "http://www.google.com";

    count=0
    preload= new Array()
    for(i =0 ; i < picture.length; i++){
    preload[i] = new Image();
    preload[i].src = picture[i];
    }

    function control(how){
    if (how=="F"){count++}
    if (how=="B"){count--}

    if(count<0){count=picture.length-1}
    if(count>picture.length-1){count=0}

    if (document.all){
    document.images.picturebox.style.filter="blendTrans(duration=2)";
    document.images.picturebox.style.filter="blendTrans(duration=CrossFadeDuration)";
    document.images.picturebox.filters.blendTrans.Apply();
    }

    document.images.picturebox.src = picture[count]
    document.images.captionbox.src = caption[count]
    document.getElementById("theLink").href = links[count];

    if (document.all){
    document.images.picturebox.filters.blendTrans.Play();
    }

    }
    function MM_preloadImages() { //v3.0
    var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
    }
    function MM_swapImgRestore() { //v3.0
    var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
    }
    function MM_findObj(n, d) { //v4.01
    var p,i,x; if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
    if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
    for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
    if(!x && d.getElementById) x=d.getElementById(n); return x;
    }
    function MM_swapImage() { //v3.0
    var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
    if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
    }
    function doImagePopUp1(){
    doImagePopUpWindow =window.open("big.htm","ImagePopup","left=20,top=150,width=450,height=251");
    }
    function setDescription(strText)
    {
    document.getElementById("objDescription").innerHTML = strText;
    }

    </script>
    </head>
    <body onLoad="showHot=true;self.focus(); MM_preloadImages('pic/arr1b.gif','pic/arr2b.gif','pic/bot1.gif','pic/bot2.gif','pic/bot4.gif','pic/bot5.gif','pic/bot6.gif')">

    <div class="container">

    <div class="btnbox"><img src="pic/btn1.gif" name=captionbox width=60 height=22></div>

    <table width="390" border="0" cellspacing="0" cellpadding="0" align="right">
    <tr>
    <td width="330"><a href="#" id="theLink"><img src="pic/bcn2.jpg" name=picturebox width=330 height=220 border=0></a></td>
    <td width="60" valign="bottom"><a href="javascript:control('F');" class="aro2" ></a><a href="javascript:control('B');" class="aro1"></a></td>
    </tr>
    </table>
    </div>
    div>
    </div>
    </body>
    </html>

  • #2
    Senior Coder
    Join Date
    Aug 2002
    Location
    UK
    Posts
    2,789
    Thanks
    2
    Thanked 14 Times in 14 Posts
    The filter attribute ie IE only so you would have to use opacity.

    Take a look at this example

    http://www.huntingground.freeserve.c...mozie_fade.htm
    The silent one.

    The most dangerous thing in the world is an idea.
    The most dangerous person in the world is the one with an idea.

  • #3
    New Coder
    Join Date
    Mar 2005
    Posts
    39
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Hi

    Hi

    Thanks this might be what Im looking for, Ill have a play around with it.

    Thanks again


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •