HTML Marquees

An HTML marquee is a scrolling piece of text displayed either horizontally across or vertically down your webpage depending on the settings. This is created by using the HTML <marquee> tag.

Syntax:


<marquee>
One or more lines of text or an image
</marquee>
    

The <marquee> Tag Attributes:

  • width - Specifies the width of the marquee. This can be a value like 10 or 20% etc.
  • height - Specifies the height of the marquee. This can be a value like 10 or 20% etc.
  • direction - Specifies the direction in which the marquee should scroll. This can be a value like up, down, left, or right.
  • behavior - Specifies the type of scrolling of the marquee. This can have a value like scroll, slide, and alternate.
  • scrolldelay - Specifies how long to delay between each jump. This will have a value like 10 etc.
  • scrollamount - Specifies the speed of marquee text. This can have a value like 10 etc.
  • hspace & vspace - Specifies horizontal and vertical space around the marquee. This can be a value like 10 or 20% etc.