RESOLVED WORKSFORME Bug 38113
Disabling a 'style' element through DOM doesn't reload the style sheet
https://bugs.webkit.org/show_bug.cgi?id=38113
Summary Disabling a 'style' element through DOM doesn't reload the style sheet
Mitch 74
Reported 2010-04-26 04:20:38 PDT
Probably related to bug 14586. Webkit doesn't populate document.styleSheets with stylesheets other than the default/preferred one (no way to access alternate stylesheets for example), so there is no way to use a Javascript stylesheet switcher. The following methods don't work: - inserting a new stylesheet through Javascript then enabling it - disabling the preferred stylesheet - enabling an alternate stylesheet - disabling (as in, object.disabled=true) the (X)HTML element that loads the preferred stylesheet (STYLE or LINK tags) Untested: deleting the DOM node instead of merely disabling it Test case: http://www.arcrachatcredits.org This website disables the stylesheet 'style-vert-css2.css' loaded through a STYLE tag in the head if the document's body is smaller than 640x400 (and re-enables it if resized above said resolution). The test case works on Firefox 2.0 to 3.7a5pre, IE 7 (real and emulated) to 9, Opera 10.10. It doesn't work in Konqueror 4.2, Chromium 5.0.339, Chrome 4.1.249.1045, Safari 4.0.5 (531.22.7).
Attachments
Brent Fulgham
Comment 1 2022-07-12 12:56:00 PDT
I can't tell a difference between Safari, Chrome, or Firefox on this site. Please REOPEN this bug with a simple test case if you believe there is still an issue here.
Alexey Proskuryakov
Comment 2 2022-07-12 20:38:23 PDT
I would expect that we still have issues in this area (and other browsers might too). But someone would need to create minimized test cases.
Note You need to log in before you can comment on or make changes to this bug.