You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@httpd.apache.org by hu...@apache.org on 2012/05/08 18:42:35 UTC

svn commit: r1335626 - /httpd/httpd/trunk/docs/manual/style/xsl/common.xsl

Author: humbedooh
Date: Tue May  8 16:42:34 2012
New Revision: 1335626

URL: http://svn.apache.org/viewvc?rev=1335626&view=rev
Log:
Reverting to the old style with a static div, until a working solution can be found.

Modified:
    httpd/httpd/trunk/docs/manual/style/xsl/common.xsl

Modified: httpd/httpd/trunk/docs/manual/style/xsl/common.xsl
URL: http://svn.apache.org/viewvc/httpd/httpd/trunk/docs/manual/style/xsl/common.xsl?rev=1335626&r1=1335625&r2=1335626&view=diff
==============================================================================
--- httpd/httpd/trunk/docs/manual/style/xsl/common.xsl (original)
+++ httpd/httpd/trunk/docs/manual/style/xsl/common.xsl Tue May  8 16:42:34 2012
@@ -294,23 +294,23 @@
 <h2><a name="comments_section" id="comments_section"><xsl:value-of select="$message[@id='comments']" /></a></h2>
 <div class="warning"><strong>This section is experimental!</strong><br/>Comments placed here should not be expected 
 to last beyond the testing phase of this system, nor do we in any way guarantee that we'll read them.</div>&lf;
+<div id="disqus_thread">&lf;</div>
 <script type="text/javascript">
 <xsl:text disable-output-escaping="yes"><![CDATA[<!--//--><![CDATA[//><!--]]></xsl:text>
-var lang = '<xsl:value-of select="$doclang"/>';
-<xsl:text disable-output-escaping="yes"><![CDATA[
+var lang = '<xsl:value-of select="$doclang"/>';<![CDATA[
 var disqus_shortname = 'httpd';
 var disqus_identifier = window.location.href.replace(/(current|trunk)/, "2.4").replace(/\/[a-z]{2}\//, "/").replace(window.location.protocol, "http:") + '.' + lang;
 if (disqus_identifier.indexOf("httpd.apache.org") != -1) {
     (function() {
-                document.write('<div id="disqus_thread">&nbsp;<\/div>');
                 var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
                 dsq.src = window.location.protocol + '//' + disqus_shortname + '.disqus.com/embed.js';
             (document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
         })();
 } else {
-    document.write("Comments have been disabled for offline viewing.");
+    var text = document.createTextNode("Comments have been disabled for offline viewing.");
+    document.getElementById('disqus_thread').appendChild(text);
 }
-]]><![CDATA[//--><!]]]]>></xsl:text></script>
+]]><xsl:text disable-output-escaping="yes"><![CDATA[//--><!]]]]>></xsl:text></script>
 </div>
 </xsl:when>
 </xsl:choose>