X
HOME HTML CSS JAVASCRIPT SQL PHP JQUERY ANGULAR XML ASP.NET MORE...
REFERENCES | EXAMPLES | FORUM | ABOUT

Style animationIterationCount Property

Style Object Reference Style Object

Example

Changing the animationIterationCount property of a <div> element:

document.getElementById("myDIV").style.animationIterationCount="infinite";

Try it yourself »


Definition and Usage

The animationIterationCount property sets or returns how many times an animation should be played.


Browser Support

Internet Explorer Firefox Opera Google Chrome Safari

The animationIterationCount property is only supported in Firefox.


Syntax

Return the animationIterationCount property:

object.style.animationIterationCount

Set the animationIterationCount property:

object.style.animationIterationCount="number|infinite|initial|inherit"

Property Values

Value Description
number A number that defines how many times an animation should be played. Default value is 1
infinite Specifies that the animation should be played infinite times (for ever)
initial Sets this property to its default value. Read about initial
inherit Inherits this property from its parent element. Read about inherit

Technical Details

Default Value: 1
Return Value: A String, representing the animation-iteration-count property of an element
CSS Version CSS3


Related Pages

CSS reference: animation-iteration-count property


Style Object Reference Style Object

Your suggestion:

Close [X]

Thank You For Helping Us!

Your message has been sent to W3Schools.

Close [X]
Search w3schools.com:

WEB HOSTING

UK Reseller Hosting

WEB BUILDING

Download XML Editor FREE Website BUILDER Free HTML5 Templates FREE Website Templates Free HTML Templates

SHARE THIS PAGE

facebook