comparison Sitemap.inc.php @ 136:60bc8f62384d default tip

Use internal URL if available to generate Sitemap.
author Tom Fredrik Blenning <bfg@bfgconsult.no>
date Mon, 23 Jan 2023 00:17:36 +0100
parents b6b4a58c7625
children
comparison
equal deleted inserted replaced
135:2fe6713ccd64 136:60bc8f62384d
149 } 149 }
150 150
151 usort($urls, "cmp_length_lex"); 151 usort($urls, "cmp_length_lex");
152 152
153 foreach($urls as $location) { 153 foreach($urls as $location) {
154 $headers = Http::getHeaders($location, 5); 154 $loc=$this->options->getInternalFromExternal($location, $base);
155 $headers = Http::getHeaders($loc, 5);
155 156
156 $location = htmlentities($location); 157 $location = htmlentities($location);
157 158
158 if (array_key_exists('Last-Modified', $headers)) { 159 if (array_key_exists('Last-Modified', $headers)) {
159 $lastmod = $headers["Last-Modified"]; 160 $lastmod = $headers["Last-Modified"];