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

    scroller testo orrizzontale - comportamento strano in ie

    Salve gente, spero di ricevere da voi una soluzione al problema visto che io di PHP sono a digiuno, vi spiego, uso Joomla ed ho installato il modulo fancyscroller che potete vedere qui in fondo alla pagina, vedrete scomparire il testo a bordo pagina a sinistra in firefox, mentre in IE si disintegra non appena tocca il bordo, come si può risolvere il problema?

    Grazie.


    Codice PHP:
    <?php // no direct access
    /**
    * @package Fancy Scroller
    * @copyright Copyright (C) 2009 QubeSys Web Solutions. All rights reserved.
    * @license [url]http://www.gnu.org/copyleft/gpl.html[/url] GNU/GPL, see LICENSE.php
    */
    defined('_JEXEC') or die('Restricted access');
    $doc = &JFactory::getDocument();
    $doc->addStyleSheet('modules/mod_fancyscroller/tmpl/style.css');
    ?>
    <script type="text/javascript">
        var dhtmlgoodies_marqueeSteps = <?php echo $steps1 ?>;    // Higher = Faster, Lower = slower and more smoothly
        var dhtmlgoodies_marqueeSpeed = <?php echo $speed1 ?>;    // Lower value = Faster
        var dhtmlgoodies_marqueeStopOnMouseOver = <?php echo $onmouse1 ?>;    // Make the marquee stop moving when user moves his mouse over it
        var dhtmlgoodies_marqueePosition = '<?php echo $position1 ?>';    // "top" or "bottom"

        /* Don't change anything below here */
        var dhtmlgoodies_marqueeObj;
        var dhtmlgoodies_marqueeTextObj;
        var dhtmlgoodies_marqueeTmpStep;
        var dhtmlgoodies_marqueeTextObjects = new Array();
        var dhtmlgoodies_marqueeHiddenSpans = new Array();

        var dhtmlgoodies_marqueeIndex = 0;
        function repositionMarquee(e,timeout)
        {
            if(document.all)e=event;
            if(dhtmlgoodies_marqueePosition.toLowerCase()=='top'){
                dhtmlgoodies_marqueeObj.style.top = '0px';
            }else{
                dhtmlgoodies_marqueeObj.style.bottom = '-1px';
            }
            if(document.all && !timeout)setTimeout('repositionMarquee(false,true)',500)
        }
        function marqueeMove()
        {
            var leftPos = dhtmlgoodies_marqueeTextObj.offsetLeft;
            leftPos = leftPos - dhtmlgoodies_marqueeTmpStep;
            var rightEdge = leftPos + dhtmlgoodies_marqueeHiddenSpans[dhtmlgoodies_marqueeIndex].offsetLeft;
            if(rightEdge<0){
                leftPos = document.documentElement.offsetWidth;
                dhtmlgoodies_marqueeTextObj.style.display='none';
                dhtmlgoodies_marqueeIndex++;
                if(dhtmlgoodies_marqueeIndex>=dhtmlgoodies_marqueeTextObjects.length)dhtmlgoodies_marqueeIndex = 0;
                dhtmlgoodies_marqueeTextObj = dhtmlgoodies_marqueeTextObjects[dhtmlgoodies_marqueeIndex];
                dhtmlgoodies_marqueeTextObj.style.display='block';

            }
            dhtmlgoodies_marqueeTextObj.style.left = leftPos + 'px';

        }

        function stopMarqueeMove()
        {
            if(dhtmlgoodies_marqueeStopOnMouseOver)dhtmlgoodies_marqueeTmpStep = 0;
        }
        function resumeMarqueeMove()
        {
            dhtmlgoodies_marqueeTmpStep = dhtmlgoodies_marqueeSteps;
        }
        function initMarquee()
        {
            dhtmlgoodies_marqueeObj = document.getElementById('dhtmlgoodies_marquee');

            var spans = dhtmlgoodies_marqueeObj.getElementsByTagName('DIV');
            for(var no=0;no<spans.length;no++){
                if(spans[no].className=='textObj'){
                    if(!dhtmlgoodies_marqueeTextObj){
                        dhtmlgoodies_marqueeTextObj = spans[no];
                        spans[no].style.display='block';
                    }else spans[no].style.display='none';
                    dhtmlgoodies_marqueeTextObjects.push(spans[no]);
                    var hiddenSpan = document.createElement('SPAN');
                    hiddenSpan.innerHTML = ' '
                    spans[no].appendChild(hiddenSpan);
                    dhtmlgoodies_marqueeHiddenSpans.push(hiddenSpan);

                }
            }
            if(dhtmlgoodies_marqueePosition.toLowerCase()=='top'){
                dhtmlgoodies_marqueeObj.style.top = '0px';
            }else{
                if(document.all){
                    dhtmlgoodies_marqueeObj.style.bottom = '0px';
                }else{
                    dhtmlgoodies_marqueeObj.style.bottom = '-1px';
                }
            }




            dhtmlgoodies_marqueeObj.style.display='block';
            dhtmlgoodies_marqueeTextObj.style.left = document.documentElement.offsetWidth + 'px';
            dhtmlgoodies_marqueeObj.onmouseover = stopMarqueeMove;
            dhtmlgoodies_marqueeObj.onmouseout = resumeMarqueeMove;
            if(document.all)window.onscroll = repositionMarquee; else dhtmlgoodies_marqueeObj.style.position = 'fixed';

            dhtmlgoodies_marqueeObj.style.display='block';
            dhtmlgoodies_marqueeTmpStep = dhtmlgoodies_marqueeSteps;

            setInterval('marqueeMove()',dhtmlgoodies_marqueeSpeed);
        }
    </script>
    <div id="dhtmlgoodies_marquee">
        <div class="textObj"><span class="highlighted"><?php echo $title1 ?></span><?php echo $text1 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title2 ?></span><?php echo $text2 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title3 ?></span><?php echo $text3 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title4 ?></span><?php echo $text4 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title5 ?></span><?php echo $text5 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title6 ?></span><?php echo $text6 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title7 ?></span><?php echo $text7 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title8 ?></span><?php echo $text8 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title9 ?></span><?php echo $text9 ?></div>
        <div class="textObj"><span class="highlighted"><?php echo $title10 ?></span><?php echo $text10 ?></div>
    </div>

    <script type="text/javascript">
    initMarquee();    // Initialize marquee script
    </script>

  2. #2
    Questo è javascript non php...
    La differenza fra la genialità e la stupidità è che la genialità ha i suoi limiti.


  3. #3
    Hai ragione furbostandby, da qui avrete capito la mia totale ignoranza su questi linguaggi, mi ero limitato a leggere la prima riga di codice con apertura <?php, è da li ho pensato male

    Va be ma per il problema cosa mi dite? Si può fare qualcosa?

    Grazie

  4. #4
    Ora non so, ma potrebbe essere che si debba intervenire su gli altri file che sono:

    mod_fancyscroller.php
    mod_fancyscroller.xml

    style.css

    Se servono posto il codice

    Sono sicuro che per qualcuno di voi non sarà difficile capire cos'è

  5. #5
    ragazzi volete aiutarmi, io non so cosa bisogna modificare per farlo ragionare in internet explorer, ma qualche geniaccio del forum di sicuro si.

    Avanti, fate una buona azione

  6. #6
    Allora ho visto che anche in Chrome no va bene, non è che magari cambiando qualcosa al file .css si potrebbe risolvere?


    html{
    height:100%;
    font-family: Segoe UI,Tahoma,Verdana,Arial;
    }
    body{
    margin:0px;
    padding:0px;
    text-align:left;
    height:100%;
    }
    #mainContainer{
    width:760px;
    border-left:1px solid #000;
    border-right:1px solid #000;
    margin:0 auto;
    height:100%;
    text-align:left;
    }
    #topRow{

    }
    #mainContent{
    padding-left:10px;
    padding-right:10px;
    }

    #dhtmlgoodies_marquee{
    /* general marquee layout*/
    padding-top:3px;
    height:25px;
    background-color: #111;


    /* End general marquee layout */


    position:absolute;
    left:0px;
    z-index:1000;
    bottom:0px;
    display:none;
    width:100%;
    overflow:hidden;
    }
    body > div#dhtmlgoodies_marquee{ /* Firefox rule */
    position:fixed;
    }
    #dhtmlgoodies_marquee .textObj{ /* Layout for the marquee text */
    position:absolute;
    color: #FFF;
    font-weight:bold;
    white-space:nowrap;
    font-family: Segoe UI,Tahoma,Verdana,Arial;
    font-size:15px;
    }
    /* Just some layout classes used in this example script */
    .highlighted{
    color:#F00; // Red color
    }
    .greenText{
    color:#0F0; // Green color
    }

    Spero almeno in una vostra risposta

  7. #7
    Non capisco perchè non ricevo risposte é una cosa impossibile da farsi?

    In ogni caso mi farebbe piacere avere una risposta per capire se è fattibile o meno, se è difficile o meno

    Stiamo a vedere

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 © 2024 vBulletin Solutions, Inc. All rights reserved.