From 0dceb18223d4cfe5dcf6468d3a3085f9433cc260 Mon Sep 17 00:00:00 2001
From: Mark Craig <mark.craig@forgerock.com>
Date: Wed, 29 Jun 2011 16:20:39 +0000
Subject: [PATCH] Clean up HTML-generation-specific XSL and insert Google analytics code in chunked version of HTML.
---
opendj-sdk/opendj3/pom.xml | 15 +++++++++++++++
opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/chunked.xsl | 4 ++--
opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/coredoc.xsl | 13 -------------
3 files changed, 17 insertions(+), 15 deletions(-)
diff --git a/opendj-sdk/opendj3/pom.xml b/opendj-sdk/opendj3/pom.xml
index af8762c..aa5b29d 100644
--- a/opendj-sdk/opendj3/pom.xml
+++ b/opendj-sdk/opendj3/pom.xml
@@ -276,6 +276,21 @@
value="legalnotice.html">
<include name="**/**/**/*.html" />
</replace>
+ <replace
+ dir="${basedir}/target/docbkx/html/"
+ token="</body>">
+ <include name="**/**/**/*.html" />
+ <replacevalue><script type="text/javascript">
+ var _gaq = _gaq || [];
+ _gaq.push(['_setAccount', 'UA-23412190-2']);
+ _gaq.push(['_trackPageview']);
+ (function() {
+ var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true;
+ ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js';
+ var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s);
+ })();
+</script></body></replacevalue>
+ </replace>
</postProcess>
</configuration>
</execution>
diff --git a/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/chunked.xsl b/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/chunked.xsl
index 97da16f..fe5d166 100644
--- a/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/chunked.xsl
+++ b/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/chunked.xsl
@@ -37,13 +37,13 @@
appendix nop
article/appendix nop
article nop
- book toc,title,figure,table,example,equation
+ book toc,title
chapter nop
part toc,title
preface nop
qandadiv nop
qandaset nop
- reference nop
+ reference toc,title
sect1 nop
sect2 nop
sect3 nop
diff --git a/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/coredoc.xsl b/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/coredoc.xsl
index 6694ba5..4563cab 100644
--- a/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/coredoc.xsl
+++ b/opendj-sdk/opendj3/src/main/docbkx-stylesheets/html/coredoc.xsl
@@ -26,22 +26,9 @@
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
version="1.0">
<xsl:import href="urn:docbkx:stylesheet" />
-
-<!-- <xsl:param name="chunk.section.depth" select="0" />-->
-<!-- <xsl:param name="chunker.output.encoding">UTF-8</xsl:param>-->
-<!-- <xsl:param name="chunker.output.indent">yes</xsl:param>-->
<xsl:param name="generate.legalnotice.link" select="1" />
-<!-- <xsl:param name="generate.revhistory.link" select="1" />-->
<xsl:param name="root.filename">index</xsl:param>
<xsl:param name="use.id.as.filename" select="1" />
-<!-- <xsl:template name="user.footer.content">-->
-<!-- <a>-->
-<!-- <xsl:attribute name="href">-->
-<!-- <xsl:apply-templates select="//legalnotice[1]" mode="chunk-filename" />-->
-<!-- </xsl:attribute>-->
-<!-- <xsl:apply-templates select="//copyright[1]" mode="titlepage.mode" />-->
-<!-- </a>-->
-<!-- </xsl:template>-->
<xsl:param name="generate.toc">
appendix nop
article/appendix nop
--
Gitblit v1.10.0