From: <al...@us...> - 2008-09-24 22:05:34
|
Revision: 696 http://sciret.svn.sourceforge.net/sciret/?rev=696&view=rev Author: alpeb Date: 2008-09-24 22:05:30 +0000 (Wed, 24 Sep 2008) Log Message: ----------- fixed more RSS issues Modified Paths: -------------- trunk/views/Rss.php Modified: trunk/views/Rss.php =================================================================== --- trunk/views/Rss.php 2008-09-24 22:00:45 UTC (rev 695) +++ trunk/views/Rss.php 2008-09-24 22:05:30 UTC (rev 696) @@ -39,8 +39,11 @@ $config = new Configuration(); + $baseLink = 'http://' . $_SERVER['HTTP_HOST'] . $_SERVER['REQUEST_URI']; + $baseLink = substr($baseLink, 0, strrpos($baseLink, '/') + 1); + $this->tpl->set_var(array( - 'link' => htmlspecialchars(Library::getLink()), + 'link' => $baseLink . htmlspecialchars(Library::getLink()), 'version' => $config->getConfigValue('version'), )); @@ -61,7 +64,8 @@ // use html_entity_decode(strip_tags()) for text nodes instead // of just htmlspecialchars() because RSS only accepts a few HTML entities $this->tpl->set_var(array( - 'art_link' => htmlspecialchars($article->isBookmark()? $article->getURL(true) : Library::getLink(array('view' => 'ViewArticle', 'id' => $article->getId()))), + 'art_link' => ($article->isBookmark()? '' : $baseLink ) + . htmlspecialchars($article->isBookmark()? $article->getURL(true) : Library::getLink(array('view' => 'ViewArticle', 'id' => $article->getId()))), 'art_title' => strip_tags($article->getTitle()), 'art_date' => date('r', strtotime($article->getModifiedByUserId() > 0? $article->getModificationDate() : $article->getCreationDate())), 'art_excerpt' => html_entity_decode(strip_tags($article->getExcerpt()).($article->isBookmark()? '' : '...'), This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |