Home >Web Front-end >JS Tutorial >How to implement jquery text scrolling up and down_jquery

How to implement jquery text scrolling up and down_jquery

WBOY
WBOYOriginal
2016-05-16 17:39:281441browse

Copy code The code is as follows:

//Scroll up and down

var textRoll=function(){

$('#notice p:last').css({'height':'0px','opacity': '0'}).insertBefore('#notice p:first').animate({' height':'35px','opacity': '1'}, 'slow', function() { $(this).removeAttr('style');});

$(function(){

//Trigger context word scroll event

var roll=setInterval('textRoll()',4000);

$("#notice p").hover(function() {

clearInterval(roll);

                                                                                                                                                           

                                                                                                                                                                                                                                                                            to  

                                                                                                  

        });

Statement:
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn