Click to return to the DHTML, HTML     
progressBehavior Property     REPEATDUR Attribute | rep...     Default Behaviors Referen...    
Web Workshop  |  DHTML, HTML & CSS

REPEAT Attribute | repeat Property


This document describes technologies available as an experimental implementation of HTML+TIME within Internet Explorer 5. While we encourage you to evaluate these features and to send us your feedback, please note that these features are subject to change.

Sets or retrieves the number of times an element's timeline repeats.

Syntax

HTML <ELEMENT STYLE="behavior:url(#default#time);" t:REPEAT = vRepetitions... >
Scripting object.repeat [ = vRepetitions ]

Possible Values

vRepetitions Variant that specifies one of the following values:
indefiniteTimeline repeats indefinitely.
repetitionsFloating-point number greater than 0 that specifies how many times the timeline repeats.

The property is read/write with a default value of 1. This property cannot be modified in script after the onload event fires on the document body.

Remarks

Use the DUR or END attribute to define each repeat iteration. The REPEAT attribute has no effect if the duration is not defined or is indefinite.

Do not use this property on the same element as the REPEATDUR attribute. Typically, REPEAT is set on elements that are time containers, such as the PAR or SEQ element. Elements containing the TIMELINE attribute are also time containers. If you set the REPEAT attribute on an element that is not a time container, it increases the element's duration by multiplying the duration by the repeat count. This causes the element to remain active on the timeline for the increased duration, but it doesn't change the element's appearance as it repeats the local timeline.

The prefix t is used to associate this attribute with an XML namespace.

Example

This example uses the REPEAT attribute to display a series of three different paragraphs over time.

Sample Code

<!DOCTYPE HTML PUBLIC "-//W3C//DTD W3 HTML//EN">
<HTML>
<HEAD>
<STYLE>
.time        { behavior: url(#default#time);}
</STYLE>
</HEAD>
<BODY BGCOLOR="white">
<P>Three paragraphs will appear for three seconds each, on 
three-second intervals, and the entire process repeats 
three times.<P>
<SPAN ID="parent" CLASS=time t:BEGIN="0" t:DUR="9" t:TIMELINE="par" 
t:REPEAT="3" t:TIMEACTION="display">
    <SPAN ID="span1" CLASS=time STYLE="COLOR:Red;" t:BEGIN="0" 
    t:DUR="3" t:TIMEACTION="visibility">
        <H3>Paragraph 1</H3>
        <P>This is paragraph number one.</P>
    </SPAN>
    <SPAN ID="span2" CLASS=time STYLE="COLOR:Blue;" t:BEGIN="3" 
    t:DUR="3" t:TIMEACTION="visibility">
        <H3>Paragraph 2</H3>
        <P>This is paragraph number two.</P>
    </SPAN>
    <SPAN ID="span3" CLASS=time STYLE="COLOR:Green;" t:BEGIN="6" 
    t:DUR="3" t:TIMEACTION="visibility">
        <H3>Paragraph 3</H3>
        <P>This is paragraph number three.</P>
    </SPAN>
</SPAN>
</BODY>
</HTML>
This feature requires Internet Explorer 5 or later. Click the icon below to install the latest version. Then reload this page to view the sample.
Microsoft Internet Explorer

Applies To

[ Object Name ]
PlatformVersion
Win16:
Win32:
Mac:
Unix:
WinCE:
animation, audio, img, media, par, seq, time, video

See Also

HTML+TIME


Back to topBack to top

Did you find this topic useful? Suggestions for other topics? Write us!

© 1999 Microsoft Corporation. All rights reserved. Terms of use.