Permalink
Browse files

Added Mark as Read link in plain messages

  • Loading branch information...
acolangelo committed Jun 2, 2011
1 parent 2ca38e8 commit 1c7dd9daef3846e16f58c7aec6521380ddcac001
Showing with 2 additions and 0 deletions.
  1. +2 −0 framework5/wddsocial/view/messages/ConversationView.php
@@ -101,11 +101,13 @@ private function renderMessagePlain($message) {
# save sender id
$this->_lastMessageId = $message->fromUserID;
$messageContent = nl2br($message->messageContent);
+ $markAsRead = ($message->messageStatusID == 1 and $message->fromUserID != UserSession::userid())?"<a href=\"/message/read/{$message->messageID}\" title=\"Mark Message As Read\" class=\"markasread\">Mark as Read</a> <span class=\"hidden\">|</span> ":'';
$linkedMessageContent = Formatter::format_links($messageContent);
$html = <<<HTML
<article>
<p>{$linkedMessageContent}</p>
+ <p>{$markAsRead}<span class="time">{$message->date}</span></p>
<p>{$message->date}</p>
</article>
HTML;

0 comments on commit 1c7dd9d

Please sign in to comment.