summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/action.php17
-rw-r--r--lib/noticelist.php4
-rw-r--r--lib/router.php5
-rw-r--r--lib/rssaction.php6
-rw-r--r--lib/subgroupnav.php68
-rw-r--r--lib/util.php5
6 files changed, 59 insertions, 46 deletions
diff --git a/lib/action.php b/lib/action.php
index fc123a633..6a69d2651 100644
--- a/lib/action.php
+++ b/lib/action.php
@@ -353,7 +353,7 @@ class Action extends HTMLOutputter // lawsuit
{
$this->elementStart('body', (common_current_user()) ? array('id' => $this->trimmed('action'),
'class' => 'user_in')
- : array('id' => $this->trimmed('action')));
+ : array('id' => $this->trimmed('action')));
$this->elementStart('div', array('id' => 'wrap'));
if (Event::handle('StartShowHeader', array($this))) {
$this->showHeader();
@@ -437,10 +437,10 @@ class Action extends HTMLOutputter // lawsuit
_('Connect'), _('Connect to SMS, Twitter'), false, 'nav_connect');
}
$this->menuItem(common_local_url('invite'),
- _('Invite'),
- sprintf(_('Invite friends and colleagues to join you on %s'),
- common_config('site', 'name')),
- false, 'nav_invitecontact');
+ _('Invite'),
+ sprintf(_('Invite friends and colleagues to join you on %s'),
+ common_config('site', 'name')),
+ false, 'nav_invitecontact');
$this->menuItem(common_local_url('logout'),
_('Logout'), _('Logout from the site'), false, 'nav_logout');
}
@@ -597,7 +597,10 @@ class Action extends HTMLOutputter // lawsuit
'class' => 'system_notice'));
$this->element('dt', null, _('Page notice'));
$this->elementStart('dd');
- $this->showPageNotice();
+ if (Event::handle('StartShowPageNotice', array($this))) {
+ $this->showPageNotice();
+ Event::handle('EndShowPageNotice', array($this));
+ }
$this->elementEnd('dd');
$this->elementEnd('dl');
}
@@ -635,7 +638,7 @@ class Action extends HTMLOutputter // lawsuit
$this->elementStart('div', array('id' => 'aside_primary',
'class' => 'aside'));
if (Event::handle('StartShowExportData', array($this))) {
- $this->showExportData();
+ $this->showExportData();
Event::handle('EndShowExportData', array($this));
}
if (Event::handle('StartShowSections', array($this))) {
diff --git a/lib/noticelist.php b/lib/noticelist.php
index 55dd902b4..004905056 100644
--- a/lib/noticelist.php
+++ b/lib/noticelist.php
@@ -187,7 +187,7 @@ class NoticeListItem extends Widget
function showNotice()
{
-if (0)
+if(0)
$this->out->elementStart('entry-title');
else
@@ -236,7 +236,7 @@ else
$clip .= '.png';
$top = '20px';
}
-if (0)
+if(0)
$this->out->elementStart('div', 'entry-attachments');
else
$this->out->elementStart('p', array('class' => 'entry-attachments', 'style' => "float: right; width: $width_att; background: url($clip) no-repeat; text-align: right; height: $height;"));
diff --git a/lib/router.php b/lib/router.php
index f07e59373..70ee0f3fb 100644
--- a/lib/router.php
+++ b/lib/router.php
@@ -426,6 +426,11 @@ class Router
array('size' => '(original|96|48|24)',
'nickname' => '[a-zA-Z0-9]{1,64}'));
+ $m->connect(':nickname/tag/:tag/rss',
+ array('action' => 'userrss'),
+ array('nickname' => '[a-zA-Z0-9]{1,64}'),
+ array('tag' => '[a-zA-Z0-9]+'));
+
$m->connect(':nickname/tag/:tag',
array('action' => 'showstream'),
array('nickname' => '[a-zA-Z0-9]{1,64}'),
diff --git a/lib/rssaction.php b/lib/rssaction.php
index ddba862dc..2f25ed7e4 100644
--- a/lib/rssaction.php
+++ b/lib/rssaction.php
@@ -97,7 +97,11 @@ class Rss10Action extends Action
// Parent handling, including cache check
parent::handle($args);
// Get the list of notices
- $this->notices = $this->getNotices($this->limit);
+ if (empty($this->tag)) {
+ $this->notices = $this->getNotices($this->limit);
+ } else {
+ $this->notices = $this->getTaggedNotices($this->tag, $this->limit);
+ }
$this->showRss();
}
diff --git a/lib/subgroupnav.php b/lib/subgroupnav.php
index 31c3ea0b5..4a9b36ae8 100644
--- a/lib/subgroupnav.php
+++ b/lib/subgroupnav.php
@@ -74,38 +74,44 @@ class SubGroupNav extends Widget
$this->out->elementStart('ul', array('class' => 'nav'));
- $this->out->menuItem(common_local_url('subscriptions',
- array('nickname' =>
- $this->user->nickname)),
- _('Subscriptions'),
- sprintf(_('People %s subscribes to'),
- $this->user->nickname),
- $action == 'subscriptions',
- 'nav_subscriptions');
- $this->out->menuItem(common_local_url('subscribers',
- array('nickname' =>
- $this->user->nickname)),
- _('Subscribers'),
- sprintf(_('People subscribed to %s'),
- $this->user->nickname),
- $action == 'subscribers',
- 'nav_subscribers');
- $this->out->menuItem(common_local_url('usergroups',
- array('nickname' =>
- $this->user->nickname)),
- _('Groups'),
- sprintf(_('Groups %s is a member of'),
- $this->user->nickname),
- $action == 'usergroups',
- 'nav_usergroups');
- if (!is_null($cur) && $this->user->id === $cur->id) {
- $this->out->menuItem(common_local_url('invite'),
- _('Invite'),
- sprintf(_('Invite friends and colleagues to join you on %s'),
- common_config('site', 'name')),
- $action == 'invite',
- 'nav_invite');
+ if (Event::handle('StartSubGroupNav', array($this))) {
+
+ $this->out->menuItem(common_local_url('subscriptions',
+ array('nickname' =>
+ $this->user->nickname)),
+ _('Subscriptions'),
+ sprintf(_('People %s subscribes to'),
+ $this->user->nickname),
+ $action == 'subscriptions',
+ 'nav_subscriptions');
+ $this->out->menuItem(common_local_url('subscribers',
+ array('nickname' =>
+ $this->user->nickname)),
+ _('Subscribers'),
+ sprintf(_('People subscribed to %s'),
+ $this->user->nickname),
+ $action == 'subscribers',
+ 'nav_subscribers');
+ $this->out->menuItem(common_local_url('usergroups',
+ array('nickname' =>
+ $this->user->nickname)),
+ _('Groups'),
+ sprintf(_('Groups %s is a member of'),
+ $this->user->nickname),
+ $action == 'usergroups',
+ 'nav_usergroups');
+ if (!is_null($cur) && $this->user->id === $cur->id) {
+ $this->out->menuItem(common_local_url('invite'),
+ _('Invite'),
+ sprintf(_('Invite friends and colleagues to join you on %s'),
+ common_config('site', 'name')),
+ $action == 'invite',
+ 'nav_invite');
+ }
+
+ Event::handle('EndSubGroupNav', array($this));
}
+
$this->out->elementEnd('ul');
}
}
diff --git a/lib/util.php b/lib/util.php
index 25c0fb0a1..fbef8764a 100644
--- a/lib/util.php
+++ b/lib/util.php
@@ -496,11 +496,6 @@ function common_linkify($url) {
}
$attrs = array('href' => $longurl, 'rel' => 'external');
-if(0){
- if ($longurl !== $url) {
- $attrs['title'] = $longurl;
- }
-}
return XMLStringer::estring('a', $attrs, $display);
}