Marquee Tag in HTML Example

Marquee Tag in HTML Example for beginners to design a webpage. Marquee is one of the most important HTML tags for supporting scrollable texts and images on a web page. In this tutorial, you’ll learn how to use the Marquee tag and its various attributes to create a well-kept static website.

The tag is an HTML container tag that is used to create scrollable text or images on a web page from left to right or vice versa, or from top to bottom. This tag, however, has been deprecated in HTML 5’s new version. These are main important tag like marquee tag in  html.

Marquee Attributes

The width or breadth of a marquee is determined by width.  

height specifies the marquee’s height or length. 

The direction of your marquee’s scrolling will be determined by this value. 

This attribute’s value can be left, right, up, or down. 

Scrolldelay is a feature that will be used to delay each jump based on its value. 

scrollamount is useful for accelerating the marquee feature. 

The scrolling type in a marquee is provided by behaviour. 

Sliding, scrolling, or alternate scrolling are all options. 

The number of times the marquee will loop is specified by loop. 

bgcolor returns a background colour whose value is either the color’s name or its hexadecimal colour code.

Vertical space is provided by vspace, which can be specified as vspace=”20″ or vspace=”30 percent.”

hspace=”20″ or hspace=”30 percent” is an example of a horizontal space provided by hspace.

Scrolls Upwards

<marquee width=”60%” direction=”up” height=”100px”> Welcome to InlarnDotcom </marquee>

Scrolls Downwards

<marquee width=“60%” direction=“down” height=“100px”> Welcome to InlarnDotcom </marquee>

Scrolls Left to Right

<marquee width=“60%” direction=“right” height=“100px”> Left to Right </marquee>

Scrolls Right to Left

<marquee width=“60%” direction=“left” height=“100px”> Right to Left </marquee>

Scrolling Speed to Execute Marquee HTML

The “scrollmount” attribute can be used to change the speed of the marquee. If you use scrollmount = “2,” for example, the marque will scroll very slowly, and as you increase “scrollmount,” the scrolling speed will increase as well.

<marquee behavior=”scroll” direction=”up” scrollamount=”1″>Slow Scrolling</marquee>

<marquee behavior=”scroll” direction=”right” scrollamount=”10″>Little Fast Scrolling</marquee>

<marquee behavior=”scroll” direction=”left” scrollamount=”15″>Fast Scrolling</marquee> 

<marquee behavior=”scroll” direction=”right” scrollamount=”100″>Very Fast Scrolling</marquee>