martin2k

The MARQUEE Tag

HomeForumTutorials Tags:
 
 

Name

Scrolling Marquee

Description

Defines a marquee - text, which scrolls horizontally across the screen.

Some attributes are not supported in Internet Explorer or Firefox.

Attributes

ALIGN

Aligns the marquee on the screen if the width is less than 100%.  Values include 'left' (default), 'middle', 'center' and 'right'.

BEHAVIOR

Specifies how the text will move:

Value Meaning
alternate The text will move from the left side of the screen to the right
scroll (default) The text will move from one side of the screen to the other and go off the edge of the page
slide The text will move from one side of the screen to the other and stop at the end of the page

BGCOLOR

Specifies the background colour.  The colour will display on the entire area that the text can scroll in.

Colours can be defined in this format: #RRGGBB where the values are in hexadecimal format.  E.g. #FF0000 is red.  Colours can also be defined with words e.g. red.

DIRECTION

Specifies the direction the text will move - either left (default) or right.

HEIGHT

Defines the height of the scrolling area.  Specifiy either as pixels or as a percent. 

LOOP

If omitted, the text will scroll indefinitely.  Otherwise it will loop the number of times specified.

SCROLLAMOUNT

Specifies the amount of pixels the text will move, each time it moves.  Default is 6.

SCROLLDELAY

Specifies the number of milliseconds between each movement of the text.  Default is 90.

WIDTH

Defines the width of the scrolling area.  Specifiy either as pixels or as a percent.

Example

Code

<marquee align="right" behavior="alternate" bgcolor="#FF0080" direction="right" height="50" loop="6" scrollamount="10" scrolldelay="100" width="75%">Scrolling Text</marquee>

Generates

Scrolling Text

Code

<marquee>Scrolling Text</marquee>

Generates

Scrolling Text


Please fill in the below form if you have any comments or additional information you want to add about the above information.  If you have any questions, please visit the ForumAny questions sent using this form will be ignored.

* - Mandatory

*Name: E-mail:

*Comments:

*Please type the following code (your comment cannot be accepted without it):


© Martin Allen 1999 - 2006.  Last updated Sunday 15 October 2006 08:08:31 PM +0100.