JavaScript Reference/Javascript Properties/pseudoClass
Версия от 18:30, 25 мая 2010; (обсуждение)
Содержание
"pseudoClass" Example
<html>
<head>
<style>@page:first { background-color: blue; }</style>
<script language="JavaScript">
function function1() {
var m = document.styleSheets[0].pages[0];
alert(m.pseudoClass);
}
</script>
</head>
<body>
<button onclick="function1();">First @page</button>
</body>
</html>
"pseudoClass" is applied to
+----------------+--------------------------------------------------------------+
| Applied_To |page |
+----------------+--------------------------------------------------------------+
"pseudoClass" Possible Values
Possible Values
first,
left,
right.
"pseudoClass" Syntax and Note
Note:
Read and write property.
Returns the pseudo class name to which an @page rule has been applied.
Syntax:
document.all.elementID.pseudoClass = value