Visualizzazione dei risultati da 1 a 2 su 2
  1. #1

    Scroll JS con OPERA 9.1 non funziona

    Buon giorno, ho uno scroll per le news, che non funziona con OPERA 9.1, mentre con il resto dei browser va benissimo.
    Il problema è anche un'altro, nel senso che, le news vengono visualizzate all'interno di un DIV che, solo con OPERA presenta i due scrollbars (Orizzontale e Verticale), mentre negl'altri no.
    Sapete come toglierli?
    Questo è lo script:
    codice:
    <style type="text/css">
    
    #marqueecontainer{
    	background-color:trasparent;
    	position: relative;
    	font-family:Verdana, Arial, Helvetica, sans-serif;
    	font-size:10px;
    	color:#000000;
    	width: 145px; /*marquee width */
    	height: 210px; /*marquee height */
    	overflow: hidden;
    	border: 0px solid silver;
    	padding: 2px;
    	padding-left: 4px;
    }
    
    </style>
    
    <script type="text/javascript">
    var delayb4scroll=5000
    var marqueespeed=1
    var pauseit=3
    
    var copyspeed=marqueespeed
    var pausespeed=(pauseit==0)? copyspeed: 0
    var actualheight=''
    
    function scrollmarquee(){
    if (parseInt(cross_marquee.style.top)>(actualheight*(-1)+8))
    cross_marquee.style.top=parseInt(cross_marquee.style.top)-copyspeed+"px"
    else
    cross_marquee.style.top=parseInt(marqueeheight)+8+"px"
    }
    
    function initializemarquee(){
    cross_marquee=document.getElementById("vmarquee")
    cross_marquee.style.top=0
    marqueeheight=document.getElementById("marqueecontainer").offsetHeight
    actualheight=cross_marquee.offsetHeight
    if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){//if Opera or Netscape 7x, add scrollbars to scroll and exit
    cross_marquee.style.height=marqueeheight+"px"
    cross_marquee.style.overflow="scroll"
    return
    }
    setTimeout('lefttime=setInterval("scrollmarquee()",30)', delayb4scroll)
    }
    
    if (window.addEventListener)
    window.addEventListener("load", initializemarquee, false)
    else if (window.attachEvent)
    window.attachEvent("onload", initializemarquee)
    else if (document.getElementById)
    window.onload=initializemarquee
    
    </script>
    
    Sapete come far funzionare lo scroll anche per OPERA e togliere le scrollbars (Orizzontale e Verticale).
    Grazie mille...

  2. #2
    ok ok, fermi tutti...ho risolto!!!
    Dovevo soltanto togliere questa porzione di codice:

    codice:
    function initializemarquee(){
    cross_marquee=document.getElementById("vmarquee")
    cross_marquee.style.top=0
    marqueeheight=document.getElementById("marqueecontainer").offsetHeight
    actualheight=cross_marquee.offsetHeight
    /*if (window.opera || navigator.userAgent.indexOf("Netscape/7")!=-1){ //if Opera or Netscape 7x, add scrollbars to scroll and exit
    cross_marquee.style.height=marqueeheight+"px"
    cross_marquee.style.overflow="scroll"
    return
    }*/
    setTimeout('lefttime=setInterval("scrollmarquee()",30)', delayb4scroll)
    }
    grazie mille....alla prox

Permessi di invio

  • Non puoi inserire discussioni
  • Non puoi inserire repliche
  • Non puoi inserire allegati
  • Non puoi modificare i tuoi messaggi
  •  
Powered by vBulletin® Version 4.2.1
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved.