<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="bbPress/1.1" -->
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom">
	<channel>
		<title>THE MOLITOR FORUMS &#187; Topic: Slider broken in Chrome when child theme is active -with fix</title>
		<link>http://www.themolitor.com/forums/topic/slider-broken-in-chrome-when-child-theme-is-active-with-fix</link>
		<description>THE MOLITOR FORUMS &#187; Topic: Slider broken in Chrome when child theme is active -with fix</description>
		<language>en-US</language>
		<pubDate>Tue, 05 May 2026 23:03:30 +0000</pubDate>
		<generator>http://bbpress.org/?v=1.1</generator>
		<textInput>
			<title><![CDATA[Search]]></title>
			<description><![CDATA[Search all topics from these forums.]]></description>
			<name>q</name>
			<link>http://www.themolitor.com/forums/search.php</link>
		</textInput>
		<atom:link href="http://www.themolitor.com/forums/rss/topic/slider-broken-in-chrome-when-child-theme-is-active-with-fix" rel="self" type="application/rss+xml" />

		<item>
			<title>awethuproject on "Slider broken in Chrome when child theme is active -with fix"</title>
			<link>http://www.themolitor.com/forums/topic/slider-broken-in-chrome-when-child-theme-is-active-with-fix#post-13520</link>
			<pubDate>Fri, 03 Aug 2012 11:05:09 +0000</pubDate>
			<dc:creator>awethuproject</dc:creator>
			<guid isPermaLink="false">13520@http://www.themolitor.com/forums/</guid>
			<description><p>TLDR; Slider breaks in Chrome when child theme is active due to NETEYE Activity Indicator jQuery Plugin's use of document.styleSheets[1].insertRule(rule) which triggers an error because the stylesheet begins with @import.</p>
<p>This can be fixed by replacing:</p>
<p>	document.styleSheets[0].insertRule(rule);</p>
<p>			with</p>
<p>	document.styleSheets[0].insertRule(rule, document.styleSheets[0].cssRules.length);</p>
<p>			on line 150 of the (unminified) Activity Indicator plugin (So, one would have to remove the minified Activity indicator, and replace it with the unmodified, then patched version).</p>
<p>Deets<br />
=====<br />
The home page slider used to be fine, but then one day I noticed that it stopped working in Google Chrome (still works in other browsers).  I checked the JS console and noticed that a the following error is logged: "Uncaught Error: HIERARCHY_REQUEST_ERR: DOM Exception 3"</p>
<p>After a bit of troubleshooting, I determined that the issue only occurs when a child theme is active. Even the simplest child theme without any changes will cause the problem to occur. For example, this minimal child theme style would trigger it:</p>
<p>///////////////////////////////////////////////////////<br />
	/*<br />
	Theme Name:     WPAID Child Test<br />
	Theme URI:      <a href="http://www.awethuproject.co.za/" rel="nofollow">http://www.awethuproject.co.za/</a><br />
	Description:    Child theme for the WP Aid theme<br />
	Author:         Go Media<br />
	Author URI:     <a href="http://gomedia.us" rel="nofollow">http://gomedia.us</a><br />
	Template:       wpaid<br />
	Version:        1.0<br />
	*/</p>
<p>	@import url("../wpaid/style.css");<br />
///////////////////////////////////////////////////////</p>
<p>Heading on down the rabbit hole, I then determined that the error was being generated by the NETEYE Activity Indicator jQuery Plugin that's included in the wpaid/scripts/scripts.js file.</p>
<p>I commented out the minified Activity Indicator plugin, and grabbed the unminified version (which hasn't been updated btw) from <a href="https://github.com/neteye/jquery-plugins/blob/master/activity-indicator/activity-indicator.js" rel="nofollow">https://github.com/neteye/jquery-plugins/blob/master/activity-indicator/activity-indicator.js</a></p>
<p>The code that's triggering the error is on line 150 (from the link above):<br />
	document.styleSheets[0].insertRule(rule);</p>
<p>This seems to be happening because Chrome doesn't like it when you insert a rule before the @import/@charset rules, as discussed here:<br />
<a href="http://code.google.com/p/chromium/issues/detail?id=135524" rel="nofollow">http://code.google.com/p/chromium/issues/detail?id=135524</a><br />
(fix) <a href="https://github.com/neteye/jquery-plugins/pull/47" rel="nofollow">https://github.com/neteye/jquery-plugins/pull/47</a></p>
<p>This is understandable, since the @import rules are supposed to come before any other rules, but it presents a problem because child themes will inherently begin with the @import rule.</p>
<p>I have applied the fix, and it's working, but I'm hoping that you might update the theme with the patched JS.</p>
<p>Chrome 21.0.1180.60 m<br />
WP 3.4.1<br />
WP Aid 1.1.1 (Unmodified)<br />
(Child theme stylesheet above)
</p></description>
		</item>

	</channel>
</rss>
