HTML: Marquee, Scrolling Text
“Marquee element” is invented by Microsoft back around 1999. It is used to make text or images to automatically scroll. Typically, in a horizontal strip.
HTML Marquee
Here is the code:
<marquee bgcolor="yellow" width="600" height="50">The BOSS IS ON A ROLL</marquee>
“marquee” element's attributes:
loop="-1"
- a integer. Number of times to loop. “-1” means forever. Default value is “-1”
direction="left"
-
left
,right
,up
,down
. Default isleft
behavior="scroll"
-
scroll
,slide
,alternate
. Default isscroll
scrolldelay="85"
- update interval for scroll movement, in milliseconds. Default is 85. Smaller than 60 is ignored, 60 is used instead, unless truespeed is specified.
truespeed
- see: scrolldelay. This is not well supported.
scrollamount="6"
- amount of scrolling update, in pixels.
hspace="30"
- horizontal margin
vspace="10"
- vertical margin
width="600"
- width in CSS pixel. 〔see What is a CSS Pixel?〕
height="40"
- width in CSS pixel.
bgcolor
- CSS color value. 〔see CSS Color Syntax〕
The “marquee” element is supported by all browsers.
CSS Marquee
You can emulate marquee using CSS animation. 〔see CSS: Animation〕
See also: CSS: OverFlow, Scrollbar