From 8330c4613b849901c58c50a32fd98ec360e2f9e4 Mon Sep 17 00:00:00 2001 From: pecesama Date: Sat, 8 Nov 2008 07:18:35 +0000 Subject: [PATCH] Updated to sitemap protocol 0.9 Implementation of getPermalink on rss.php --- notice.txt | 6 ++- rss.php | 4 +- sitemap.php | 42 +++++++++------------ sitemap.xsl | 107 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 4 files changed, 131 insertions(+), 28 deletions(-) create mode 100644 sitemap.xsl diff --git a/notice.txt b/notice.txt index ffbfc79..9c524f8 100644 --- a/notice.txt +++ b/notice.txt @@ -11,8 +11,12 @@ Juan del Rio [ http://elcaminante.net/ ] = COPYRIGHT NOTICES = This product includes code and libraries developed by third parties, which are governed by different licenses. These components, and their licenses, are listed below. += XSLT template for sitemap = +Copyright (c) Arne Brachhold, http://www.arnebrachhold.de/ +XSLT template for sitemap available under GNU General Public License. + = Services_JSON = -Copyright (c)Michal Migurski, Matt Knapp and Brett Stimmerman, http://mike.teczno.com/JSON/JSON.phps +Copyright (c) Michal Migurski, Matt Knapp and Brett Stimmerman, http://mike.teczno.com/JSON/JSON.phps Services_JSON is available under BSD license. = Archive based on code from: simple Tumblr API processor = diff --git a/rss.php b/rss.php index 48c69c3..d50e5ba 100644 --- a/rss.php +++ b/rss.php @@ -77,8 +77,8 @@ if(!defined('entry')) define('entry',true); break; } $tit = util::trimString($tit); - $strEnd = ($conf->urlFriendly) ? "/" : ""; - $url = $conf->urlGelato.($conf->urlFriendly ? "/post/" : "/index.php?post=").$register["id_post"].$strEnd; + $strEnd = ($conf->urlFriendly) ? "/" : ""; + $url = $tumble->getPermalink($register["id_post"]); $formatedDate = gmdate("r", strtotime($register["date"]) + util::transform_offset($conf->offsetTime)); ?> diff --git a/sitemap.php b/sitemap.php index b0e483c..a8196e5 100644 --- a/sitemap.php +++ b/sitemap.php @@ -12,54 +12,46 @@ if(!defined('entry')) define('entry',true); =========================== */ ?> \n"; + echo "urlGelato."/sitemap.xsl\"?>\n"; $rs = $tumble->getPosts(1); ?> - - - + - urlGelato;?> - 0.9 + urlGelato;?> contarRegistros()>0) { + if ($db->contarRegistros()>0) { $register = mysql_fetch_array($rs); $formatedDate = gmdate("Y-m-d", strtotime($register["date"])); - echo "".$formatedDate.""; + echo "\n\t".$formatedDate.""; } ?> - hourly + hourly + 0.9 getPosts($tumble->getPostsNumber()); - if ($tumble->contarRegistros()>0) { - while($register = mysql_fetch_array($rs)) { - $url = htmlspecialchars($conf->urlGelato."/index.php?post=".$register["id_post"]); + if ($db->contarRegistros()>0) { + while($register = mysql_fetch_array($rs)) { + $url = $tumble->getPermalink($register["id_post"]); $formatedDate = gmdate("Y-m-d", strtotime($register["date"])); ?> - - 0.7 + - daily + daily + 0.7 + + + + + + XML Sitemap + + + + +

XML Sitemap

+
+

+ This is a XML Sitemap which is supposed to be processed by search engines like Google, MSN Search and YAHOO.
+ It was generated using the Tumblelogging-Software Gelato CMS.
+ You can find more information about XML sitemaps on sitemaps.org and Google's list of sitemap programs. +

+
+
+ + + + + + + + + + + + + high + + + + + + + +
URLPriorityChange FrequencyLastChange
+ + + + + + + + + + + + +
+
+ + + +
+
\ No newline at end of file