aboutsummaryrefslogtreecommitdiff
path: root/views/default/page/elements/page_links.php
diff options
context:
space:
mode:
Diffstat (limited to 'views/default/page/elements/page_links.php')
-rw-r--r--views/default/page/elements/page_links.php37
1 files changed, 37 insertions, 0 deletions
diff --git a/views/default/page/elements/page_links.php b/views/default/page/elements/page_links.php
new file mode 100644
index 000000000..fb9acbfb7
--- /dev/null
+++ b/views/default/page/elements/page_links.php
@@ -0,0 +1,37 @@
+<?php
+/**
+ * Page links: RSS link, reported content link, etc.
+ */
+
+// Are there feeds to display?
+global $autofeed;
+$rss_link = '';
+if (isset($autofeed) && $autofeed == true) {
+ $url = full_url();
+ if (substr_count($url,'?')) {
+ $url .= "&view=rss";
+ } else {
+ $url .= "?view=rss";
+ }
+ $url = elgg_format_url($url);
+ $label = elgg_echo('feed:rss');
+
+ $rss_link = elgg_view('output/url', array(
+ 'text' => '<span class="elgg-icon elgg-icon-rss"></span>',
+ 'href' => $url,
+ 'title' => $label,
+ 'rel' => 'nofollow',
+ 'encode_text' => false,
+ 'class' => 'right',
+ ));
+}
+
+// view to extend by plugins
+$links = elgg_view('page/links', $vars);
+
+if ($links || $rss_link) {
+ echo '<div class="elgg-page-links clearfix mbm">';
+ echo $rss_link;
+ echo $links;
+ echo '</div>';
+}