Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ticker stopping after first cycle #38

Open
mcdesignpro opened this issue Dec 7, 2016 · 7 comments
Open

Ticker stopping after first cycle #38

mcdesignpro opened this issue Dec 7, 2016 · 7 comments

Comments

@mcdesignpro
Copy link

Is there a way to have the ticker scrolling in an infinite loop?

@mcdesignpro mcdesignpro changed the title Ticker stopping after firstcycle Ticker stopping after first cycle Dec 7, 2016
@Martin-Andersen
Copy link

I have the exact same problem. If I have one item in the list it will scroll forever. In my current example I have three items and it stops after number three.

I really need some help. It's production time on monday, no pressure (-:

HTML structure

<div class="news-ticker-container">
    <div class="tickercontainer" style="height: 30px; overflow: hidden;">
        <div class="mask">
            <ul id="webticker" style="position: relative; overflow: hidden; float: left; font-style: normal; font-variant: normal; font-weight: bold; font-stretch: normal; font-size: 10px; line-height: normal; font-family: Verdana; list-style-type: none; margin: 0px; padding: 0px; width: 2331px; transition-timing-function: linear; transition-duration: 0s; left: 0px;">
                <li class="ticker-spacer" style="float: left;width:-15px;height:30px;"></li>
                <li class="breaking-news-item" style="white-space: nowrap; float: left; padding: 0px 7px; line-height: 30px;">Dette er en test - for her kommer til at stå noget</li>
                <li class="breaking-news-item" style="white-space: nowrap; float: left; padding: 0px 7px; line-height: 30px;">Dette er en test - for her kommer til at stå noget</li>
                <li class="breaking-news-item last" style="white-space: nowrap; float: left; padding: 0px 7px; line-height: 30px;">Dette er en test - hello world</li>
            </ul><span class="tickeroverlay-left" style="display: none;">&nbsp;</span><span class="tickeroverlay-right" style="display: none;">&nbsp;</span></div>
    </div>
</div>

@Martin-Andersen
Copy link

It's working now. I created a simple stub project and it worked.

Then I took another look at my code and realised that I have wrapped the list in a div with class="tickercontainer" no need to do that it's the job of the webticker.

So thanks for a great plugin look real good on my site.

@mcdesignpro
Copy link
Author

mcdesignpro commented Dec 15, 2016

In order to slide in a infinite loop you need to put the content inside only one list tag.

@HaydenMoore
Copy link

adding <li class="last"></li> after the last list item should allow for an infinite loop of the data. I had the same issue and this seemed to fix my problem.

@WilsonBrett
Copy link

WilsonBrett commented Nov 30, 2017

I just tried adding the empty li with class=last and it still stopped looping after only one loop. I ended up commenting out line 160 ($strip.append('<li class="ticker-spacer" style="float: '+settings.direction+';width:'+emptySpace+'px;height:'+height+'px;"></li>');) which appends the space ticker to the list and now it doesn't stop looping which appears to fix the bug for me.

@SuperShalabi
Copy link

Adding <li class="ticker-spacer"></li> as the first item in addition to @HaydenMoore's suggestion worked for me.

@ducdung0909
Copy link

I experienced the same issue and followed by theses suggestions. The ticker scrolls in infinite loop but I see a blink at last of cycle. It's not smooth as expected. Can someone give more suggestions ? thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants