PluginProbe
Yoast SEO – Advanced SEO with real-time guidance and built-in AI / trunk
Yoast SEO – Advanced SEO with real-time guidance and built-in AI vtrunk
28.5 28.4 28.3 28.2 28.1 28.0 27.9 27.8 27.7 27.6 27.5 trunk 18.0 18.1 18.2 18.3 18.4 18.4.1 18.5 18.5.1 18.6 18.7 18.8 18.9 19.0 All 129 releases
wordpress-seo / css / main-sitemap.xsl

main-sitemap.xsl in Yoast SEO – Advanced SEO with real-time guidance and built-in AI trunk, at css/main-sitemap.xsl

146 lines 4.1 KB
No matching file
Up and down to move Enter to open Esc to close
Raw Download Zip
1 <?xml version="1.0" encoding="UTF-8"?>
2 <xsl:stylesheet version="2.0"
3 xmlns:html="http://www.w3.org/TR/REC-html40"
4 xmlns:image="http://www.google.com/schemas/sitemap-image/1.1"
5 xmlns:sitemap="http://www.sitemaps.org/schemas/sitemap/0.9"
6 xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
7 <xsl:output method="html" version="1.0" encoding="UTF-8" indent="yes"/>
8 <xsl:template match="/">
9 <html xmlns="http://www.w3.org/1999/xhtml">
10 <head>
11 <title>XML Sitemap</title>
12 <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
13 <style type="text/css">
14 body {
15 font-family: Helvetica, Arial, sans-serif;
16 font-size: 13px;
17 color: #545353;
18 }
19 table {
20 border: none;
21 border-collapse: collapse;
22 }
23 #sitemap tr:nth-child(odd) td {
24 background-color: #eee !important;
25 }
26 #sitemap tbody tr:hover td {
27 background-color: #ccc;
28 }
29 #sitemap tbody tr:hover td, #sitemap tbody tr:hover td a {
30 color: #000;
31 }
32 #content {
33 margin: 0 auto;
34 width: 1000px;
35 }
36 .expl {
37 margin: 18px 3px;
38 line-height: 1.2em;
39 }
40 .expl a {
41 color: #da3114;
42 font-weight: 600;
43 }
44 .expl a:visited {
45 color: #da3114;
46 }
47 a {
48 color: #000;
49 text-decoration: none;
50 }
51 a:visited {
52 color: #777;
53 }
54 a:hover {
55 text-decoration: underline;
56 }
57 td {
58 font-size:11px;
59 }
60 th {
61 text-align:left;
62 padding-right:30px;
63 font-size:11px;
64 }
65 thead th {
66 border-bottom: 1px solid #000;
67 }
68 </style>
69 </head>
70 <body>
71 <div id="content">
72 <h1>XML Sitemap</h1>
73 <p class="expl">
74 Generated by <a href="https://yoa.st/1y5" target="_blank" rel="noopener">Yoast SEO</a>, this is an XML Sitemap, meant for consumption by search engines.<br/>
75 You can find more information about XML sitemaps on <a href="https://sitemaps.org" target="_blank" rel="noopener">sitemaps.org</a>.
76 </p>
77 <xsl:if test="count(sitemap:sitemapindex/sitemap:sitemap) &gt; 0">
78 <p class="expl">
79 This XML Sitemap Index file contains <xsl:value-of select="count(sitemap:sitemapindex/sitemap:sitemap)"/> sitemaps.
80 </p>
81 <table id="sitemap" cellpadding="3">
82 <thead>
83 <tr>
84 <th width="75%">Sitemap</th>
85 <th width="25%">Last Modified</th>
86 </tr>
87 </thead>
88 <tbody>
89 <xsl:for-each select="sitemap:sitemapindex/sitemap:sitemap">
90 <xsl:variable name="sitemapURL">
91 <xsl:value-of select="sitemap:loc"/>
92 </xsl:variable>
93 <tr>
94 <td>
95 <a href="{$sitemapURL}"><xsl:value-of select="sitemap:loc"/></a>
96 </td>
97 <td>
98 <xsl:value-of select="concat(substring(sitemap:lastmod,0,11),concat(' ', substring(sitemap:lastmod,12,5)),concat(' ', substring(sitemap:lastmod,20,6)))"/>
99 </td>
100 </tr>
101 </xsl:for-each>
102 </tbody>
103 </table>
104 </xsl:if>
105 <xsl:if test="count(sitemap:sitemapindex/sitemap:sitemap) &lt; 1">
106 <p class="expl">
107 This XML Sitemap contains <xsl:value-of select="count(sitemap:urlset/sitemap:url)"/> URLs.
108 </p>
109 <table id="sitemap" cellpadding="3">
110 <thead>
111 <tr>
112 <th width="80%">URL</th>
113 <th width="5%">Images</th>
114 <th title="Last Modification Time" width="15%">Last Mod.</th>
115 </tr>
116 </thead>
117 <tbody>
118 <xsl:variable name="lower" select="'abcdefghijklmnopqrstuvwxyz'"/>
119 <xsl:variable name="upper" select="'ABCDEFGHIJKLMNOPQRSTUVWXYZ'"/>
120 <xsl:for-each select="sitemap:urlset/sitemap:url">
121 <tr>
122 <td>
123 <xsl:variable name="itemURL">
124 <xsl:value-of select="sitemap:loc"/>
125 </xsl:variable>
126 <a href="{$itemURL}">
127 <xsl:value-of select="sitemap:loc"/>
128 </a>
129 </td>
130 <td>
131 <xsl:value-of select="count(image:image)"/>
132 </td>
133 <td>
134 <xsl:value-of select="concat(substring(sitemap:lastmod,0,11),concat(' ', substring(sitemap:lastmod,12,5)),concat(' ', substring(sitemap:lastmod,20,6)))"/>
135 </td>
136 </tr>
137 </xsl:for-each>
138 </tbody>
139 </table>
140 </xsl:if>
141 </div>
142 </body>
143 </html>
144 </xsl:template>
145 </xsl:stylesheet>
146