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

    Scroll non funziona con mozilla

    Ciao Ragazzi, io ho uno script che funziona alla grande su explorer ma non con mozilla...purtroppo non so proprio come metterci mano anche perchè l'ho preso da un sito opensource....il problema è che su mozilla non si vedono tutte le immagini ma a un certo punto si blocca, sapreste dirmi come posso intervenire?!?!?!?!?!?!
    questo il codice......
    #divUpControl{position:absolute; left:330; top:10; z-index:1; text-align: right}
    #divDownControl{position:absolute; left:330; top:270; z-index:1; text-align: right}
    #divLeftControl{
    position:absolute;
    left:700px;
    top:80px;
    z-index:1;
    text-align: right;
    width: 100px;
    }
    #divRightControl{
    position:absolute;
    left:680px;
    top:620px;
    z-index:1;
    text-align: right;
    width: 50px;
    }
    #divContainer{position:absolute; width:300px; height:140px; overflow:hidden; top:15px; left:379px; clip:rect(0 300 240 0); visibility:visible}

    #divContent{
    position:absolute;
    width: 600px;
    top:24px;
    left:0px;
    visibility: visible;
    }
    .style2 { color: #FFFFFF;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 10px;
    }
    .style3 {font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 10px;
    font-weight: bold;
    }
    body {
    background-color: #8E9193;
    margin-left: 0px;
    margin-top: 0px;
    margin-right: 0px;
    margin-bottom: 0px;
    }
    a:link {
    text-decoration: none;
    color: #869519;
    }
    a:visited {
    text-decoration: none;
    color: #FFFFFF;
    }
    a:hover {
    text-decoration: none;
    }
    a:active {
    text-decoration: none;
    color: #FFFFFF;
    }
    .style4 {
    color: #B1BF0D;
    font-weight: bold;
    }
    .style5 {color: #333333}
    </style>
    <script language="JavaScript">
    <!--

    // begin absolutely positioned scrollable area object scripts

    function verifyCompatibleBrowser(){
    this.ver=navigator.appVersion
    this.dom=document.getElementById?1:0
    this.ie5=(this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
    this.ie4=(document.all && !this.dom)?1:0;
    this.ns5=(this.dom && parseInt(this.ver) >= 5) ?1:0;

    this.ns4=(document.layers && !this.dom)?1:0;
    this.bw=(this.ie5 || this.ie4 || this.ns4 || this.ns5)
    return this
    }
    bw=new verifyCompatibleBrowser()


    var speed=50

    var loop, timer

    function ConstructObject(obj,nest){
    nest=(!nest) ? '':'document.'+nest+'.'
    this.el=bw.dom?document.getElementById(obj):bw.ie4 ?document.all[obj]:bw.ns4?eval(nest+'document.'+obj):0;
    this.css=bw.dom?document.getElementById(obj).style :bw.ie4?document.all[obj].style:bw.ns4?eval(nest+'document.'+obj):0;
    this.scrollHeight=bw.ns4?this.css.document.height: this.el.offsetHeight
    this.clipHeight=bw.ns4?this.css.clip.height:this.e l.offsetHeight
    this.up=MoveAreaUp;this.down=MoveAreaDown;

    this.scrollWidth=bw.ns4?this.css.document.width:th is.el.offsetWidth
    this.clipWidth=bw.ns4?this.css.clip.width:this.el. offsetWidth
    this.left=MoveAreaLeft;this.right=MoveAreaRight;


    this.MoveArea=MoveArea; this.x=0; this.y=0;
    this.obj = obj + "Object"
    eval(this.obj + "=this")
    return this
    }
    function MoveArea(x,y){
    this.x=x;this.y=y
    this.css.left=this.x
    this.css.top=this.y
    }

    function MoveAreaDown(move){
    if(this.y>-this.scrollHeight+objContainer.clipHeight){
    this.MoveArea(this.x,this.y-move)
    if(loop) setTimeout(this.obj+".down("+move+")",speed)
    }
    }
    function MoveAreaUp(move){
    if(this.y<0){
    this.MoveArea(this.x,this.y-move)
    if(loop) setTimeout(this.obj+".up("+move+")",speed)
    }
    }
    function MoveAreaRight(move){
    if(-this.x + objContainer.clipWidth < this.scrollWidth){
    this.MoveArea(this.x-move,this.y)
    if(loop) setTimeout(this.obj+".right("+move+")",speed)
    }
    window.status = "right no action " + this.x;
    }
    function MoveAreaLeft(move){
    if(this.x<0){
    this.MoveArea(this.x-move,this.y)
    if(loop) setTimeout(this.obj+".left("+move+")",speed)
    }
    window.status = "left no action " + this.x;
    }

    function PerformScroll(direction,speed){
    if(initialised){
    loop=true;
    if(direction == 0)
    {
    if(speed>0) objScroller.down(speed)
    else objScroller.up(speed)
    }
    else
    {
    if(speed>0) objScroller.right(speed)
    else objScroller.left(speed)
    }
    }
    }

    function CeaseScroll(){
    loop=false
    if(timer) clearTimeout(timer)
    }
    var initialised;
    function InitialiseScrollableArea(){
    objContainer=new ConstructObject('divContainer')
    objScroller=new ConstructObject('divContent','divContainer')
    objScroller.MoveArea(0,0)
    objContainer.css.visibility='visible'
    initialised=true;
    }


    che fare?
    Grzie per avermi letto!!

  2. #2
    Utente di HTML.it
    Registrato dal
    Aug 2002
    Messaggi
    8,013
    Che fare? postare nella sezione corretta: JavaScript
    Qui si tratta Java
    <´¯)(¯`¤._)(¯`»ANDREA«´¯)(_.¤´¯)(¯`>
    "The answer to your question is: welcome to tomorrow"

  3. #3

    questo dimostra quanto ne capisco è già la seconda volta che sbaglio!!!
    sono una testona!!!
    scusate!!!

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.