Html Tutorial

HTML-Marquee

Use of Marquee?

<Marquee> is used to give a scrolling effect to a text.It is not recommended to use marquee as it is not supported by many browsers.

Example:

<body>
<marquee> Tutorial Heap </marquee>
</body>

Output:


 Tutorial Heap 

Attributes of Marquee?

As other tags <Marquee> also have attributes. Few of them is given below.

1.direction

direction attribute of marquee specifies the direction of motion of text.

Example:

<body>
 <marquee direction="down"> Tutorial Heap </marquee>
  <marquee direction="up"> Tutorial Heap </marquee>
  <marquee direction="right"> Tutorial Heap </marquee>
  <marquee direction="left"> Tutorial Heap </marquee>
</body>

Output:


   Tutorial Heap 
   Tutorial Heap 
   Tutorial Heap 
   Tutorial Heap 

2. scrolldelay

scrolldelay attribute is used to set speed of marquee text. More the value of scrolldelay, less will be the speed of text.

Explain:

<body>
<marquee scrolldelay="1"> Tutorial Heap </marquee>
<marquee scrolldelay="400"> Tutorial Heap </marquee>
<marquee scrolldelay="900"> Tutorial Heap </marquee>
<marquee scrolldelay="1200"> Tutorial Heap </marquee>
</body>

Output:


   Tutorial Heap 
   Tutorial Heap 
   Tutorial Heap 
   Tutorial Heap 

Advertisment

Share


Advertisement