Properties of ‘marquee’ tag and its different Attributes

In this HTML tutorial, today we will learn about a single tag, named as the marquee. The marquee tag comes in a pair. In other words, it has an opening as well as the closing tag. The marquee tag is used to create a scrolling effect, on text or an image. It is used to make the text or image to scroll vertically down or horizontally across in the web page.

Free cool 3d image hover effect source code download

Marquee tag and attributes in HTML

Here I am providing an HTML code to get the scrolling effect. You can customize it to make changes in this effect.

<!DOCTYPE html>
    <title>Use of marquee tag </title>
      <h1><marquee = "any attributes">Codespeedy</marquee></h1>
      Codespeedy word is scrolling with the help of marquee tag.

List of attributes of Marquee tag in HTML

These are the following attributes which you can use to adjust the look of the marquee tag:

Attribute Value Description
behavior scroll
Specifies the scrolling type.
bg-color rgb(x,x,x)
colour name
With the help of this, we can provide a background colour.
direction up
Specifies the direction of the scrolling.
height pixels
Specifies the height of content inside the marquee tag.
h-space pixels Specifies the horizontal space across the marquee tag.
loop number Specifies, how many times the content will scroll. And if we don’t define this, the content will scroll without stopping.
scroll-amount number Specifies the scrolling amount at each interval in pixels. And its default value is 6.
scroll-delay seconds Specifies how long delay will be between each jump. And its default value is 85 and the amount less than 60 will be ignored.
true-speed seconds Basically, it is used to delay the scroll lesser than 60.
v-space pixels Specifies the vertical space between the content inside the marquee tag.
width pixels
Specifies the width of content inside the marquee tag.

Note: The marquee tag is a non-standard HTML tag. If you use this tag, your pages or apps may be broken or not work properly.

Also read,

Leave a Reply

Your email address will not be published. Required fields are marked *