aboutsummaryrefslogtreecommitdiff
path: root/mod/profile/views
diff options
context:
space:
mode:
Diffstat (limited to 'mod/profile/views')
-rw-r--r--mod/profile/views/default/profile/profile_contents/feeds.php20
-rwxr-xr-xmod/profile/views/default/profile/profile_navigation.php11
2 files changed, 30 insertions, 1 deletions
diff --git a/mod/profile/views/default/profile/profile_contents/feeds.php b/mod/profile/views/default/profile/profile_contents/feeds.php
new file mode 100644
index 000000000..bff9ea1ea
--- /dev/null
+++ b/mod/profile/views/default/profile/profile_contents/feeds.php
@@ -0,0 +1,20 @@
+<?php
+/**
+ * Elgg profile feeds page
+ */
+
+//$twitter_username = $vars['entity']->twitter;
+$page_owner = page_owner();
+$feeds = elgg_get_entities(array('types' => 'object', 'subtypes' => 'aggregator_feed_url', 'owner_guids' => $page_owner));
+
+// if the twitter username is empty, then do not show
+?>
+<div id="profile_content">
+<?php
+if($feeds){
+ echo elgg_view('aggregator/profile',array('feeds'=>$feeds));
+}else{
+ echo "This user has not added any feeds.";
+}
+?>
+</div> \ No newline at end of file
diff --git a/mod/profile/views/default/profile/profile_navigation.php b/mod/profile/views/default/profile/profile_navigation.php
index 1c2c782c7..a08cd847d 100755
--- a/mod/profile/views/default/profile/profile_navigation.php
+++ b/mod/profile/views/default/profile/profile_navigation.php
@@ -30,7 +30,10 @@ switch($section){
case 'commentwall':
$commentwall = 'class="selected"';
break;
-
+ case 'feeds':
+ $feeds = 'class="selected"';
+ break;
+
case 'activity':
default:
$activity = 'class="selected"';
@@ -45,6 +48,12 @@ switch($section){
<li <?php echo $friends; ?>><a href="<?php echo $url . 'friends'; ?>">Friends</a></li>
<li <?php echo $commentwall; ?>><a href="<?php echo $url . 'commentwall'; ?>">Comment Wall</a></li>
<?php
+ //check to see if the aggregator plugin is enabled
+ if(is_plugin_enabled('aggregator')){
+ ?>
+ <li <?php echo $feeds; ?>><a href="<?php echo $url . 'feeds'; ?>">Feeds</a></li>
+ <?php
+ }
//check to see if the twitter username is set
if($vars['entity']->twitter){
?>