aboutsummaryrefslogtreecommitdiff
path: root/mod/messages
diff options
context:
space:
mode:
authorpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-22 13:31:19 +0000
committerpete <pete@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-03-22 13:31:19 +0000
commita140ef9c53edb2e249eab2eafccc6eb8c0952dab (patch)
tree84e077e486a56a115a0defb8667f5409456ab470 /mod/messages
parentc8e1a99c0388710806012eaad59e700c0667a4d1 (diff)
downloadelgg-a140ef9c53edb2e249eab2eafccc6eb8c0952dab.tar.gz
elgg-a140ef9c53edb2e249eab2eafccc6eb8c0952dab.tar.bz2
Updated avatar menu: Removed links to tools, provided a view to extend menu, added @username to menu, cleaned-up and simplified menu generation.
git-svn-id: http://code.elgg.org/elgg/trunk@5467 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/messages')
-rw-r--r--mod/messages/start.php2
-rw-r--r--mod/messages/views/default/messages/menu.php15
2 files changed, 6 insertions, 11 deletions
diff --git a/mod/messages/start.php b/mod/messages/start.php
index b74402ac3..6e130edca 100644
--- a/mod/messages/start.php
+++ b/mod/messages/start.php
@@ -44,7 +44,7 @@ function messages_init() {
// Register a URL handler for shouts posts
register_entity_url_handler('messages_url','object','messages');
- // Extend hover-over and profile menu
+ // Extend avatar user-menu
elgg_extend_view('profile/menu/links','messages/menu');
// Register a notification handler for site messages
diff --git a/mod/messages/views/default/messages/menu.php b/mod/messages/views/default/messages/menu.php
index 150c9a73c..5afb7d409 100644
--- a/mod/messages/views/default/messages/menu.php
+++ b/mod/messages/views/default/messages/menu.php
@@ -8,14 +8,9 @@
* @copyright Curverider Ltd 2008-2010
* @link http://elgg.com/
*/
-
- //need to be logged in to send a message
- if (isloggedin()) {
-?>
- <li class="user_menu_messages">
- <a href="<?php echo $vars['url']; ?>mod/messages/send.php?send_to=<?php echo $vars['entity']->guid; ?>"><?php echo elgg_echo("messages:sendmessage"); ?></a>
- </li>
-
-<?php
-} \ No newline at end of file
+// login check already performed in profile/icon
+?>
+<li class="user_menu_profile">
+ <a class="send_message" href="<?php echo $vars['url']; ?>mod/messages/send.php?send_to=<?php echo $vars['entity']->guid; ?>"><?php echo elgg_echo("messages:sendmessage"); ?></a>
+</li> \ No newline at end of file