[Webkit-unassigned] [Bug 40578] New: insertRule throws exception for rules starting with '@'
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Jun 14 11:15:53 PDT 2010
https://bugs.webkit.org/show_bug.cgi?id=40578
Summary: insertRule throws exception for rules starting with
'@'
Product: WebKit
Version: 528+ (Nightly build)
Platform: PC
URL: http://pastie.org/1003535
OS/Version: Mac OS X 10.5
Status: UNCONFIRMED
Severity: Normal
Priority: P2
Component: HTML DOM
AssignedTo: webkit-unassigned at lists.webkit.org
ReportedBy: jos.van.den.oever at kogmbh.com
Created an attachment (id=58673)
--> (https://bugs.webkit.org/attachment.cgi?id=58673)
html with javascript that calls insertRule
Programmatically building a stylesheet is currently not possible since the insertRule function throws and exception if a rule is added that contains an '@'.
This works fine in Firefox 3.6.3.
http://www.w3.org/TR/DOM-Level-2-Style/css.html
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>CSS: insertRule with @namespace gives exception</title>
<style type="text/css" id='css'>
</style>
<script type="text/javascript" charset="utf-8">
function init() {
var stylesheet = document.getElementById('css').sheet;
stylesheet.insertRule(
'@namespace text url(urn:oasis:names:tc:opendocument:xmlns:text:1.0)',
stylesheet.cssRules.length);
document.getElementById('body').innerHTML = 'Call to insertRule was ok.';
}
</script>
</head>
<body onload='init()' id='body'>
insertRule has not been called yet.
</body>
</html>
--
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the webkit-unassigned
mailing list