aboutsummaryrefslogtreecommitdiff
path: root/views/rss/pageshells
diff options
context:
space:
mode:
authorCash Costello <cash.costello@gmail.com>2009-07-03 02:13:23 +0000
committerCash Costello <cash.costello@gmail.com>2009-07-03 02:13:23 +0000
commit5e0bfcd150c5275184dd8cdc7fda2f8bd139d84d (patch)
treeea6481708574b053678bc80d54b766bf12ffbae8 /views/rss/pageshells
parent0f7a79ee3ff8b6ade335bfb4ce9d4f8b62c2c3c0 (diff)
downloadelgg-5e0bfcd150c5275184dd8cdc7fda2f8bd139d84d.tar.gz
elgg-5e0bfcd150c5275184dd8cdc7fda2f8bd139d84d.tar.bz2
forgot to include this in a previous check-in
Diffstat (limited to 'views/rss/pageshells')
-rw-r--r--views/rss/pageshells/pageshell.php46
1 files changed, 46 insertions, 0 deletions
diff --git a/views/rss/pageshells/pageshell.php b/views/rss/pageshells/pageshell.php
new file mode 100644
index 000000000..2dfc8917f
--- /dev/null
+++ b/views/rss/pageshells/pageshell.php
@@ -0,0 +1,46 @@
+<?php
+
+ /**
+ * Elgg RSS output pageshell
+ *
+ * @package Elgg
+ * @subpackage Core
+ * @license http://www.gnu.org/licenses/old-licenses/gpl-2.0.html GNU Public License version 2
+ * @copyright Curverider Ltd 2008-2009
+ * @link http://elgg.org/
+ *
+ */
+
+ header("Content-Type: text/xml");
+
+ echo "<?xml version='1.0'?>\n";
+
+
+
+ // Set title
+ if (empty($vars['title'])) {
+ $title = $vars['config']->sitename;
+ } else if (empty($vars['config']->sitename)) {
+ $title = $vars['title'];
+ } else {
+ $title = $vars['config']->sitename . ": " . $vars['title'];
+ }
+
+ // Remove RSS from URL
+ $url = str_replace('?view=rss','',full_url());
+ $url = str_replace('&view=rss','',full_url());
+
+?>
+
+<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:georss="http://www.georss.org/georss" <?php echo elgg_view('extensions/xmlns'); ?> >
+ <channel>
+ <title><![CDATA[<?php echo $title; ?>]]></title>
+ <link><?php echo htmlentities($url); ?></link>
+ <?php echo elgg_view('extensions/channel'); ?>
+ <?php
+
+ echo $vars['body'];
+
+ ?>
+ </channel>
+</rss> \ No newline at end of file