Skip to content

Commit 2947c68

Browse files
author
p12
committed
Preprocess: fix the removal of google-analytics scripts
1 parent b0f6543 commit 2947c68

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

preprocess.xsl

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,8 +90,9 @@
9090
<xsl:template match="/html/head/link[@rel = 'EditURI']"/>
9191

9292
<!-- remove Google Analytics scripts -->
93-
<xsl:template match="/html/head/script[contains(text(),'google-analytics.com/ga.js')]"/>
94-
<xsl:template match="/html/head/script[contains(text(),'pageTracker')]"/>
93+
<xsl:template match="/html/body/script[contains(text(),'google-analytics.com/ga.js')]"/>
94+
<xsl:template match="/html/body/script[contains(@src, 'google-analytics.com/ga.js')]"/>
95+
<xsl:template match="/html/body/script[contains(text(),'pageTracker')]"/>
9596

9697
<!-- update links to resources: -->
9798
<xsl:template match="//@href | //@src">

0 commit comments

Comments
 (0)