summaryrefslogtreecommitdiff
path: root/lib/action.php
diff options
context:
space:
mode:
Diffstat (limited to 'lib/action.php')
-rw-r--r--lib/action.php41
1 files changed, 27 insertions, 14 deletions
diff --git a/lib/action.php b/lib/action.php
index 89a8c8f4d..928eb48c0 100644
--- a/lib/action.php
+++ b/lib/action.php
@@ -247,7 +247,6 @@ class Action extends HTMLOutputter // lawsuit
'src' => common_path('js/jquery.joverlay.min.js')),
' ');
-
Event::handle('EndShowJQueryScripts', array($this));
}
if (Event::handle('StartShowLaconicaScripts', array($this))) {
@@ -384,15 +383,18 @@ class Action extends HTMLOutputter // lawsuit
{
$this->elementStart('address', array('id' => 'site_contact',
'class' => 'vcard'));
- $this->elementStart('a', array('class' => 'url home bookmark',
- 'href' => common_local_url('public')));
- if (common_config('site', 'logo') || file_exists(theme_file('logo.png'))) {
- $this->element('img', array('class' => 'logo photo',
- 'src' => (common_config('site', 'logo')) ? common_config('site', 'logo') : theme_path('logo.png'),
- 'alt' => common_config('site', 'name')));
+ if (Event::handle('StartAddressData', array($this))) {
+ $this->elementStart('a', array('class' => 'url home bookmark',
+ 'href' => common_local_url('public')));
+ if (common_config('site', 'logo') || file_exists(theme_file('logo.png'))) {
+ $this->element('img', array('class' => 'logo photo',
+ 'src' => (common_config('site', 'logo')) ? common_config('site', 'logo') : theme_path('logo.png'),
+ 'alt' => common_config('site', 'name')));
+ }
+ $this->element('span', array('class' => 'fn org'), common_config('site', 'name'));
+ $this->elementEnd('a');
+ Event::handle('EndAddressData', array($this));
}
- $this->element('span', array('class' => 'fn org'), common_config('site', 'name'));
- $this->elementEnd('a');
$this->elementEnd('address');
}
@@ -422,11 +424,13 @@ class Action extends HTMLOutputter // lawsuit
$this->menuItem(common_local_url('smssettings'),
_('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');
+ if (common_config('invite', 'enabled')) {
+ $this->menuItem(common_local_url('invite'),
+ _('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');
}
@@ -704,6 +708,11 @@ class Action extends HTMLOutputter // lawsuit
_('About'));
$this->menuItem(common_local_url('doc', array('title' => 'faq')),
_('FAQ'));
+ $bb = common_config('site', 'broughtby');
+ if (!empty($bb)) {
+ $this->menuItem(common_local_url('doc', array('title' => 'tos')),
+ _('TOS'));
+ }
$this->menuItem(common_local_url('doc', array('title' => 'privacy')),
_('Privacy'));
$this->menuItem(common_local_url('doc', array('title' => 'source')),
@@ -964,12 +973,16 @@ class Action extends HTMLOutputter // lawsuit
$action = $this->trimmed('action');
$args = $this->args;
unset($args['action']);
+ if (common_config('site', 'fancy')) {
+ unset($args['p']);
+ }
if (array_key_exists('submit', $args)) {
unset($args['submit']);
}
foreach (array_keys($_COOKIE) as $cookie) {
unset($args[$cookie]);
}
+
return common_local_url($action, $args);
}