This is element x. It has inline style border: 1px solid #cc0000.
Element y is the test style sheet.
Element z is the special <style> block in this page, which contains
a color declaration with !important and a normal font-size declaration.
This style sheet adds a font-size: 130%; to element x.
document.createStyleSheet('teststyleSheet2.css');
alert(z.cssRules[0].style.getPropertyPriority('color'))
alert(z.cssRules[0].style.getPropertyPriority('font-size'))
And for IE.
alert(z.rules[0].style.getPropertyPriority('color'))
alert(z.rules[0].style.getPropertyPriority('font-size'))
alert(z.cssRules[0].style.getPropertyValue('color'))
alert(z.cssRules[0].style.getPropertyValue('font-size'))
And for IE.
alert(z.rules[0].style.getPropertyValue('color'))
alert(z.rules[0].style.getPropertyValue('font-size'))
alert(y.ownerNode.nodeName)
alert(z.ownerNode.nodeName)
alert(y.cssRules[0].parentStyleSheet)
alert(z.cssRules[0].parentStyleSheet)
And for IE.
alert(y.rules[0].parentStyleSheet)
alert(z.rules[0].parentStyleSheet)
y.cssRules[y.cssRules.length-1].style.removeProperty('color');
And for IE.
y.rules[y.rules.length-1].style.removeProperty('color');
y.cssRules[y.cssRules.length-1].style.setProperty('font-size','130%',null);
And for IE.
y.rules[y.rules.length-1].style.setProperty('font-size','130%',null);