<marquee> Element

Renders as scrolling text, either horizontally or vertically.

 

Attribute Description Value
width How wide the marquee is 10, 20%
height How high the marquee is 10, 20%
direction Which direction it should scroll up, down, left, right
behaviour Type of scrolling scroll, slide, alternate
scrolldelay Delay between each scroll frame 10, 20, etc in milliseconds
scrollamount Sets the speed of scrolling 10, 20, etc in milliseconds
loop How many times to loop default is infinite
bgcolor background colour colour name or hex value
hspace Horizontal space around the marquee 10, 20%
vspace Vertical space around the marquee 10, 20%

 

 


 

An image can also be placed within a marquee to provide some basic animation, this example increases the speed of the scrolling to give a slightly smoother scroll:

 

<marquee scrollamount="50"><img src="HTML5_logo.png"></marquee>

Leave a Reply