HTML Marquee

HTML <marquee> tag is used to scrolls the image or text up, down, left or right automatically.

HTML Marquee Attributes

Attribute Description
behavior It facilitates user to set the behavior of the marquee to one of the three different types: scroll, slide and alternate.
direction defines direction for scrolling content. It may be left, right, up and down.
width defines width of marquee in pixels or %.
height defines height of marquee in pixels or %.
hspace defines horizontal space in pixels around the marquee.
vspace defines vertical space in pixels around the marquee.
scrolldelay defines scroll delay in seconds.
scrollamount defines scroll amount in number.
loop defines loop for marquee content in number.
bgcolor defines background color. It is now deprecated.

See this example:

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Example of HTML Marquee tag</title>
</head>
<body>
    <p><marquee width="100%" behavior="scroll" bgcolor="green" >This is an example of html marquee </marquee></p>
 </body>
</html>