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

    News-Ticker Orizzontale

    salve sto cercando un news ticker orizzontale come uno dei due presenti su questo sito http://www.djguide.nl/

    ho trovato questo (posto soltanto il codice html)

    <DIV ID="TICKER" STYLE="overflow:hidden; width:100%" onmouseover="TICKER_PAUSED=true" onmouseout="TICKER_PAUSED=false">
    My First News Ticker
    </DIV>
    <script src="webticker_lib.js" language="javascript"></script>

    e teoricamente mi va bene.

    La domanda è : siccome devo mettere le news con i link al posto di "My First News Ticker", se metto 1000 news, e magari il browser dell'utente non supporta il mio script, quell'utente, cosa vede ?? le 1000 news normali in formato html ? o non vede niente ?

    Sapete dove posso trovare altri esempi ? xke su html.it javascript, script, ne torvo soltanto di verticali..

    Oppure, è possibile realizzarli anche con i css ??

    Vi ringrazio tutti in anticipo

  2. #2
    scusate, questo è il .js


    // WebTicker by Mioplanet
    // www.mioplanet.com

    TICKER_CONTENT = document.getElementById("TICKER").innerHTML;

    TICKER_RIGHTTOLEFT = false;
    TICKER_SPEED = 2;
    TICKER_STYLE = "font-family:Arial; font-size:12px; color:#444444";
    TICKER_PAUSED = false;

    ticker_start();

    function ticker_start() {
    var tickerSupported = false;
    TICKER_WIDTH = document.getElementById("TICKER").style.width;
    var img = "<img src=ticker_space.gif width="+TICKER_WIDTH+" height=0>";

    // Firefox
    if (navigator.userAgent.indexOf("Firefox")!=-1 || navigator.userAgent.indexOf("Safari")!=-1) {
    document.getElementById("TICKER").innerHTML = "<TABLE cellspacing='0' cellpadding='0' width='100%'><TR><TD nowrap='nowrap'>"+img+"<SPAN style='"+TICKER_STYLE+"' ID='TICKER_BODY' width='100%'></SPAN>"+img+"</TD></TR></TABLE>";
    tickerSupported = true;
    }
    // IE
    if (navigator.userAgent.indexOf("MSIE")!=-1 && navigator.userAgent.indexOf("Opera")==-1) {
    document.getElementById("TICKER").innerHTML = "<DIV nowrap='nowrap' style='width:100%;'>"+img+"<SPAN style='"+TICKER_STYLE+"' ID='TICKER_BODY' width='100%'></SPAN>"+img+"</DIV>";
    tickerSupported = true;
    }
    if(!tickerSupported) document.getElementById("TICKER").outerHTML = ""; else {
    document.getElementById("TICKER").scrollLeft = TICKER_RIGHTTOLEFT ? document.getElementById("TICKER").scrollWidth - document.getElementById("TICKER").offsetWidth : 0;
    document.getElementById("TICKER_BODY").innerHTML = TICKER_CONTENT;
    document.getElementById("TICKER").style.display="b lock";
    TICKER_tick();
    }
    }

    function TICKER_tick() {
    if(!TICKER_PAUSED) document.getElementById("TICKER").scrollLeft += TICKER_SPEED * (TICKER_RIGHTTOLEFT ? -1 : 1);
    if(TICKER_RIGHTTOLEFT && document.getElementById("TICKER").scrollLeft <= 0) document.getElementById("TICKER").scrollLeft = document.getElementById("TICKER").scrollWidth - document.getElementById("TICKER").offsetWidth;
    if(!TICKER_RIGHTTOLEFT && document.getElementById("TICKER").scrollLeft >= document.getElementById("TICKER").scrollWidth - document.getElementById("TICKER").offsetWidth) document.getElementById("TICKER").scrollLeft = 0;
    window.setTimeout("TICKER_tick()", 30);
    }

  3. #3
    NEssuno lo sa ? forse sono i mondiali... ??

  4. #4

  5. #5
    perfetto, grazie, ma se il browser non lo supporta che succede ?

    PS. Posso anche sapere xke quel codice postato non va bene ?? curiosità, se puoi

    Grazie !

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.