Javascript [Electronic resources] : The Definitive Guide (4th Edition)

David Flanagan

نسخه متنی -صفحه : 844/ 579
نمايش فراداده

Availability

DOM Level 2 CSS

Synopsis

void deleteRule(unsigned long index) throws DOMException;

Arguments

index

The index within the cssRules array of the rule to be deleted.

Throws

This method throws a DOMException with a code of INDEX_SIZE_ERR if index is negative or greater than or equal to cssRules.length. It throws a DOMException with a code of NO_MODIFICATION_ALLOWED_ERR if this style sheet is read-only.

Description

This method deletes the rule at the specified index from the cssRules array.