aboutsummaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
Diffstat (limited to 'templates')
-rw-r--r--templates/profile.tpl.php2
-rw-r--r--templates/sidebar.block.menu2.php24
-rw-r--r--templates/sidebar.block.watchlist.php11
3 files changed, 11 insertions, 26 deletions
diff --git a/templates/profile.tpl.php b/templates/profile.tpl.php
index dda9c80..1e2003a 100644
--- a/templates/profile.tpl.php
+++ b/templates/profile.tpl.php
@@ -6,7 +6,7 @@ $this->includeTemplate($GLOBALS['top_include']);
<dt><?php echo T_('Username'); ?></dt>
<dd><?php echo $user; ?></dd>
<?php
-if ($currentUser->isAdmin()) {
+if ($userservice->isLoggedOn() && $currentUser->isAdmin()) {
?>
<dt><?php echo T_('Email'); ?></dt>
<dd><?php echo filter($objectUser->getEmail()) ?></dd>
diff --git a/templates/sidebar.block.menu2.php b/templates/sidebar.block.menu2.php
index d571120..eee150e 100644
--- a/templates/sidebar.block.menu2.php
+++ b/templates/sidebar.block.menu2.php
@@ -14,12 +14,11 @@ if ($logged_on_userid === false) {
$logged_on_userid = NULL;
}
-if(!isset($user) || $user == '') {
- $cat_url = createURL('tags', '%2$s');
-}
+$cat_url = createURL('tags', '%2$s');
$menu2Tags = $GLOBALS['menu2Tags'];
+
if (sizeOf($menu2Tags) > 0) {
$this->includeTemplate("dojo.inc");
?>
@@ -41,23 +40,8 @@ foreach($menu2Tags as $menu2Tag) {
echo '</script>';
echo '</div>';
}
-?> <!-- /table--> <?php $cUser = $userservice->getUser($userid); ?> <?php if($userid>0): ?>
-<?php if($userid==$logged_on_userid): ?>
-<p style="text-align: right"><a
- href="<?php echo createURL('alltags', $cUser['username']); ?>"
- title="<?php echo T_('See all your tags')?>"><?php echo T_('all your tags'); ?></a>
-&rarr;</p>
-<?php else: ?>
-<p style="text-align: right"><a
- href="<?php echo createURL('alltags', $cUser['username']); ?>"
- title="<?php echo T_('See all tags from this user')?>"><?php echo T_('all tags from this user'); ?></a>
-&rarr;</p>
-<?php endif; ?> <?php else : ?>
-<p style="text-align: right"><a
- href="<?php echo createURL('populartags', $cUser['username']); ?>"
- title="<?php echo T_('See popular tags')?>"><?php echo T_('Popular Tags'); ?></a>
-&rarr;</p>
-<?php endif; ?></div>
+?>
+</div>
<?php
}
diff --git a/templates/sidebar.block.watchlist.php b/templates/sidebar.block.watchlist.php
index a42acba..eaf68dc 100644
--- a/templates/sidebar.block.watchlist.php
+++ b/templates/sidebar.block.watchlist.php
@@ -3,7 +3,6 @@
//No specific services
$watching = $userservice->getWatchNames($userid);
-if ($watching) {
?>
<h2><?php echo T_('Watching'); ?></h2>
@@ -12,9 +11,11 @@ if ($watching) {
<?php foreach($watching as $watchuser): ?>
<li><a href="<?php echo createURL('bookmarks', $watchuser); ?>"><?php echo $watchuser; ?></a> &rarr;</li>
<?php endforeach; ?>
+ <li>
+ <form action="<?php echo createURL('watch', '');?>" method="post">
+ <input type="text" name="contact" value="<?php echo T_('Add a contact...');?>" onfocus="if (this.value == '<?php echo T_('Add a contact...');?>') this.value = '';" onblur="if (this.value == '') this.value = '<?php echo T_('Add a contact...');?>';" title="<?php echo T_('Type a username to add it to your contacts.') ?>" />
+ </form>
+ </li>
</ul>
-</div>
-<?php
-}
-?> \ No newline at end of file
+</div>