// Inline display the author of a message. This can be called from many different views.
// For messages originating locally, it renders the display name linked to their profile.
// For messages originating locally, it renders the display name and their email address.
-function render_msg_author(msg) {
- if (msg.locl) {
+function render_msg_author(msg, view) {
+ if ((msg.locl) && (view == views.VIEW_BBS)) {
return(
"<span class=\"ctdl-username\" onClick=\"javascript:user_profile('" + msg.from + "');\">"
+ msg.from
+ "<div class=\"ctdl-fmsg-content\">" // begin content
+ "<div class=\"ctdl-msg-header\">" // begin header
+ "<span class=\"ctdl-msg-header-info\">" // begin header info on left side
- + render_msg_author(msg) // author
+ + render_msg_author(msg, views.VIEW_BBS) // author
+ "<span class=\"ctdl-msgdate\">"
+ string_timestamp(msg.time,0)
+ "</span>" // end msgdate
// Render reply address for a message (FIXME we might want to figure out in-reply-to)
function reply_addr(msg) {
- if (msg.locl) {
- return([msg.from]);
- }
- else {
+ //if (msg.locl) {
+ //return([msg.from]);
+ //}
+ //else {
return([msg.from + " <" + msg.rfca + ">"]);
- }
+ //}
}
+ "<div class=\"ctdl-mmsg-content\">" // begin content
+ "<div class=\"ctdl-msg-header\">" // begin header
+ "<span class=\"ctdl-msg-header-info\">" // begin header info on left side
- + render_msg_author(msg)
+ + render_msg_author(msg, views.VIEW_MAILBOX)
+ "<span class=\"ctdl-msgdate\">"
+ string_timestamp(msg.time,0)
+ "</span>" // end msgdate
}
};
request.send(body_text);
-}
\ No newline at end of file
+}