summaryrefslogtreecommitdiff
path: root/utils/rss.php
diff options
context:
space:
mode:
Diffstat (limited to 'utils/rss.php')
-rw-r--r--utils/rss.php21
1 files changed, 14 insertions, 7 deletions
diff --git a/utils/rss.php b/utils/rss.php
index b4b4b86..f0ea103 100644
--- a/utils/rss.php
+++ b/utils/rss.php
@@ -46,29 +46,36 @@ class RSS {
public function write()
{
+ global $RSS_TITLE;
+ global $RSS_URL;
+ global $RSS_DESCRIPTION;
+ global $RSS_EDITOR;
+ global $RSS_WEBMASTER;
+ global $RSS_TARGET_PAGE;
+
$fp = fopen($this->rssfile, "w");
fwrite($fp, "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n");
fwrite($fp, "<rss version=\"2.0\">\n");
fwrite($fp, " <channel>\n");
- fwrite($fp, " <title>DIE News</title>\n");
- fwrite($fp, " <link>http://www.executionroom.com</link>\n");
- fwrite($fp, " <description>DIE - News from ExecutionRoom.com</description>\n");
+ fwrite($fp, " <title>".$RSS_TITLE."</title>\n");
+ fwrite($fp, " <link>".$RSS_URL."</link>\n");
+ fwrite($fp, " <description>".$RSS_DESCRIPTION."</description>\n");
fwrite($fp, " <language>en-us</language>\n");
fwrite($fp, " <pubDate>".$this->date(time())."</pubDate>\n");
fwrite($fp, " <lastBuildDate>".$this->date(time())."</lastBuildDate>\n");
fwrite($fp, " <docs>http://blogs.law.harvard.edu/tech/rss</docs>\n");
fwrite($fp, " <generator>ExecutionRoom CMS</generator>\n");
- fwrite($fp, " <managingEditor>info@executionroom.com</managingEditor>\n");
- fwrite($fp, " <webMaster>info@executionroom.com</webMaster>\n");
+ fwrite($fp, " <managingEditor>".$RSS_EDITOR."</managingEditor>\n");
+ fwrite($fp, " <webMaster>".$RSS_WEBMASTER."</webMaster>\n");
$i = 0;
foreach($this->news as $newsentry) {
fwrite($fp, " <item>\n");
fwrite($fp, " <title>".$newsentry->title."</title>\n");
- fwrite($fp, " <link>http://www.executionroom.com/?page=news&amp;id=".$newsentry->time."</link>\n");
+ fwrite($fp, " <link>".$RSS_URL."/?page=".$RSS_TARGET_PAGE."&amp;newsid=".$newsentry->time."</link>\n");
fwrite($fp, " <description>".$newsentry->description."</description>\n");
fwrite($fp, " <pubDate>".$this->date($newsentry->time)."</pubDate>\n");
- fwrite($fp, " <guid>http://www.executionroom.com/?page=news&amp;id=".$newsentry->time."&amp;newsid="+$newsentry->time+"</guid>\n");
+ fwrite($fp, " <guid>".$RSS_URL."/?page=".$RSS_TARGET_PAGE."&amp;newsid=".$newsentry->time."</guid>\n");
fwrite($fp, " </item>\n");
$i++;
if($i > 6) break;