]> granicus.if.org Git - apache/commitdiff
ignore external references in the sitemap
authorAndré Malo <nd@apache.org>
Sun, 2 Feb 2014 22:45:11 +0000 (22:45 +0000)
committerAndré Malo <nd@apache.org>
Sun, 2 Feb 2014 22:45:11 +0000 (22:45 +0000)
git-svn-id: https://svn.apache.org/repos/asf/httpd/httpd/trunk@1563740 13f79535-47bb-0310-9956-ffa450edef68

docs/manual/style/xsl/hhc.xsl
docs/manual/style/xsl/hhp.xsl

index c9fde79837ae949d40d1d298cdcf53ab73504a64..34b8aae944178c0c055c33d3518be6d79edfe67d 100644 (file)
 <!-- category/page                                                        -->
 <!-- ==================================================================== -->
 <xsl:template match="category/page">
+<xsl:if test="not(starts-with(@href,'http:') or starts-with(@href, 'https:'))">
 &li.start;
 
 <!-- document entry, if not href attribute, assume it means "sitemap" -->
 <xsl:apply-templates select="self::page" mode="index" />
 
 &li.end; &lf;&tab;
+</xsl:if>
 </xsl:template>
 <!-- /category/page -->
 
index 369377e85157218cb1f800ea2c7d4a83f8a16cd1..d8e12eed6ed3637b6eff70b72d81c505ee78077c 100644 (file)
 <!-- files referenced in sitemap                                          -->
 <!-- ==================================================================== -->
 <xsl:template match="category/page">
+<xsl:if test="not(starts-with(@href,'http:') or starts-with(@href, 'https:'))">
 <xsl:variable name="filename">
     <xsl:choose>
     <xsl:when test="contains(@href, '#') and substring(@href,
 </xsl:variable>
 
 <xsl:value-of select="translate($filename, '/', '\')" />&lf;
+</xsl:if>
 </xsl:template>
 <!-- /page[@href] -->