summaryrefslogtreecommitdiff
path: root/actions/showstream.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/showstream.php')
-rw-r--r--actions/showstream.php52
1 files changed, 30 insertions, 22 deletions
diff --git a/actions/showstream.php b/actions/showstream.php
index 11615ebb0..0c8fea182 100644
--- a/actions/showstream.php
+++ b/actions/showstream.php
@@ -111,7 +111,7 @@ class ShowstreamAction extends Action
$this->page = ($this->arg('page')) ? ($this->arg('page')+0) : 1;
common_set_returnto($this->selfUrl());
-
+
return true;
}
@@ -178,21 +178,21 @@ class ShowstreamAction extends Action
function showFeeds()
{
$this->element('link', array('rel' => 'alternate',
- 'type' => 'application/rss+xml',
- 'href' => common_local_url('userrss',
- array('nickname' => $this->user->nickname)),
- 'title' => sprintf(_('Notice feed for %s (RSS)'),
- $this->user->nickname)));
-
- $this->element('link',
- array('rel' => 'alternate',
- 'href' => common_local_url('api',
- array('apiaction' => 'statuses',
- 'method' => 'user_timeline.atom',
- 'argument' => $this->user->nickname)),
- 'type' => 'application/atom+xml',
- 'title' => sprintf(_('Notice feed for %s (Atom)'),
- $this->user->nickname)));
+ 'type' => 'application/rss+xml',
+ 'href' => common_local_url('userrss',
+ array('nickname' => $this->user->nickname)),
+ 'title' => sprintf(_('Notice feed for %s (RSS)'),
+ $this->user->nickname)));
+
+ $this->element('link',
+ array('rel' => 'alternate',
+ 'href' => common_local_url('api',
+ array('apiaction' => 'statuses',
+ 'method' => 'user_timeline.atom',
+ 'argument' => $this->user->nickname)),
+ 'type' => 'application/atom+xml',
+ 'title' => sprintf(_('Notice feed for %s (Atom)'),
+ $this->user->nickname)));
}
/**
@@ -228,7 +228,7 @@ class ShowstreamAction extends Action
// for remote subscriptions etc.
$this->element('meta', array('http-equiv' => 'X-XRDS-Location',
'content' => common_local_url('xrds', array('nickname' =>
- $this->user->nickname))));
+ $this->user->nickname))));
if ($this->profile->bio) {
$this->element('meta', array('name' => 'description',
@@ -270,6 +270,15 @@ class ShowstreamAction extends Action
'height' => AVATAR_PROFILE_SIZE,
'alt' => $this->profile->nickname));
$this->elementEnd('dd');
+
+ $user = User::staticGet('id', $this->profile->id);
+ $cur = common_current_user();
+ if ($cur && $cur->id == $user->id) {
+ $this->elementStart('dd');
+ $this->element('a', array('href' => common_local_url('avatarsettings')), _('Edit Avatar'));
+ $this->elementEnd('dd');
+ }
+
$this->elementEnd('dl');
$this->elementStart('dl', 'entity_nickname');
@@ -278,7 +287,7 @@ class ShowstreamAction extends Action
$hasFN = ($this->profile->fullname) ? 'nickname url uid' : 'fn nickname url uid';
$this->element('a', array('href' => $this->profile->profileurl,
'rel' => 'me', 'class' => $hasFN),
- $this->profile->nickname);
+ $this->profile->nickname);
$this->elementEnd('dd');
$this->elementEnd('dl');
@@ -346,7 +355,7 @@ class ShowstreamAction extends Action
$this->elementStart('li', 'entity_edit');
$this->element('a', array('href' => common_local_url('profilesettings'),
'title' => _('Edit profile settings')),
- _('Edit'));
+ _('Edit'));
$this->elementEnd('li');
}
@@ -368,9 +377,8 @@ class ShowstreamAction extends Action
$this->elementEnd('li');
}
- $user = User::staticGet('id', $this->profile->id);
if ($cur && $cur->id != $user->id && $cur->mutuallySubscribed($user)) {
- $this->elementStart('li', 'entity_send-a-message');
+ $this->elementStart('li', 'entity_send-a-message');
$this->element('a', array('href' => common_local_url('newmessage', array('to' => $user->id)),
'title' => _('Send a direct message to this user')),
_('Message'));
@@ -512,7 +520,7 @@ class ShowstreamAction extends Action
$this->elementStart('dl', 'entity_member-since');
$this->element('dt', null, _('Member since'));
$this->element('dd', null, date('j M Y',
- strtotime($this->profile->created)));
+ strtotime($this->profile->created)));
$this->elementEnd('dl');
$this->elementStart('dl', 'entity_subscriptions');