1

Is there any way to add the contents like in marquee using jquery? Basically, I want to add the different latest images for my website.

Thanks.

Ali Hassan
  • 607
  • 1
  • 11
  • 24

2 Answers2

3

Not sure if there's an agreed definition of marquee. In the context of HTML I always thought it means a text scrolling from right to left (or LTR).

I see in the comments you want items moving upward. There're surely some JQuery plugins to do it, but you can easily do it yourself. HTML:

<ul id="panel_news">
    <li>BigEvent 2012 @ Berlin, 29 Nov - 1 Dec</li>
    <li>User Group meeting hosted by ConnectUs</li>
    <li>Joan announces PXLS</li>
    <li>OpenVMS Boot Camp</li>
</ul>
<ul id="panel_news_bank" style="display: none;">
    <li>IT annual conference in Melbourne</li>
    <li>Benchmark presenation</li>
</ul>

​ and JavaScript/JQuery code:

var tickerTimer = self.setInterval("ticker()", 2500);
function ticker() {
    $("#panel_news > li").first().hide(500, function() {
        var ticker_item;
        $("#panel_news > li").first().detach().appendTo("#panel_news_bank");
        ticker_item = $("#panel_news_bank > li").first().detach();
        ticker_item.appendTo("#panel_news");
        ticker_item.fadeIn(1000);
        ticker_item = null;
    });
}

see it in action @ jsFiddle

targumon
  • 1,041
  • 12
  • 26
0

Use this JQuery plugin for marquee:

http://www.givainc.com/labs/marquee_jquery_plugin.htm

sohel khalifa
  • 5,602
  • 3
  • 34
  • 46