';
// Show the message anchor and a "new" anchor if this message is new.
if ($message['id'] != $context['first_message'])
echo '
', $message['first_new'] ? ' ' : '';
echo '
';
// Show information about the poster of this message.
echo '
', $message['member']['link'], '
';
// Show the member's custom title, if they have one.
if (isset($message['member']['title']) && $message['member']['title'] != '')
echo '
', $message['member']['title'], ' ';
// Show the member's primary group (like 'Administrator') if they have one.
if (isset($message['member']['group']) && $message['member']['group'] != '')
echo '
', $message['member']['group'], ' ';
// Don't show these things for guests.
if (!$message['member']['is_guest'])
{
// Show the post group if and only if they have no other group or the option is on, and they are in a post group.
if ((empty($settings['hide_post_group']) || $message['member']['group'] == '') && $message['member']['post_group'] != '')
echo '
', $message['member']['post_group'], ' ';
echo '
', $message['member']['group_stars'], ' ';
// Is karma display enabled? Total or +/-?
if ($modSettings['karmaMode'] == '1')
echo '
', $modSettings['karmaLabel'], ' ', $message['member']['karma']['good'] - $message['member']['karma']['bad'], ' ';
elseif ($modSettings['karmaMode'] == '2')
echo '
', $modSettings['karmaLabel'], ' +', $message['member']['karma']['good'], '/-', $message['member']['karma']['bad'], ' ';
// Is this user allowed to modify this member's karma?
if ($message['member']['karma']['allow'])
echo '
', $modSettings['karmaApplaudLabel'], '
', $modSettings['karmaSmiteLabel'], ' ';
// Show online and offline buttons?
if (!empty($modSettings['onlineEnable']) && !$message['member']['is_guest'])
echo '
', $context['can_send_pm'] ? '' : '', $settings['use_image_buttons'] ? ' ' : $message['member']['online']['text'], $context['can_send_pm'] ? ' ' : '', $settings['use_image_buttons'] ? ' ' . $message['member']['online']['text'] . ' ' : '', ' ';
// Show the member's gender icon?
if (!empty($settings['show_gender']) && $message['member']['gender']['image'] != '')
echo '
', $txt[231], ': ', $message['member']['gender']['image'], ' ';
// Show how many posts they have made.
echo '
', $txt[26], ': ', $message['member']['posts'], '
';
// Show avatars, images, etc.?
if (!empty($settings['show_user_images']) && empty($options['show_no_avatars']) && !empty($message['member']['avatar']['image']))
echo '
', $message['member']['avatar']['image'], ' ';
// Show their personal text?
if (!empty($settings['show_blurb']) && $message['member']['blurb'] != '')
echo '
', $message['member']['blurb'], '
';
// This shows the popular messaging icons.
echo '
', $message['member']['icq']['link'], '
', $message['member']['msn']['link'], '
', $message['member']['yim']['link'], '
', $message['member']['aim']['link'], ' ';
// Show the profile, website, email address, and personal message buttons.
if ($settings['show_profile_buttons'])
{
// Don't show the profile button if you're not allowed to view the profile.
if ($message['member']['can_view_profile'])
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[27]), ' ';
// Don't show an icon if they haven't specified a website.
if ($message['member']['website']['url'] != '')
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[515]), ' ';
// Don't show the email address if they want it hidden.
if (empty($message['member']['hide_email']))
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[69]), ' ';
// Since we know this person isn't a guest, you *can* message them.
if ($context['can_send_pm'])
echo '
', $settings['use_image_buttons'] ? ' ' : $message['member']['online']['label'], ' ';
}
}
// Otherwise, show the guest's email.
elseif (empty($message['member']['hide_email']))
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[69]), ' ';
// Done with the information about the poster... on to the post itself.
echo '
';
// If this is the first post, (#0) just say when it was posted - otherwise give the reply #.
echo '
« ', !empty($message['counter']) ? $txt[146] . ' #' . $message['counter'] : '', ' ', $txt[30], ': ', $message['time'], ' »
';
// Can they reply? Have they turned on quick reply?
if ($context['can_reply'] && !empty($options['display_quick_reply']))
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[145]), ' ';
// So... quick reply is off, but they *can* reply?
elseif ($context['can_reply'])
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[145]), ' ';
// Can the user modify the contents of this post?
if ($message['can_modify'])
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[17]), ' ';
// How about... even... remove it entirely?!
if ($message['can_remove'])
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt[31]), ' ';
// What about splitting it off the rest of the topic?
if ($context['can_split'])
echo '
', ($settings['use_image_buttons'] ? ' ' : $txt['smf251']), ' ';
// Show a checkbox for quick moderation?
if (!empty($options['display_quick_mod']) && $options['display_quick_mod'] == 1 && $message['can_remove'])
echo '
';
// Show the post itself, finally!
echo '
', $message['body'], '
', $message['can_modify'] ? '
' : '' , '
';
// Now for the attachments, signature, ip logged, etc...
echo '
';
// Assuming there are attachments...
if (!empty($message['attachment']))
{
echo '
';
foreach ($message['attachment'] as $attachment)
{
if ($attachment['is_image'])
{
if ($attachment['thumbnail']['has_thumb'])
echo '
';
else
echo '
';
}
echo '
' . $attachment['name'] . ' (', $attachment['size'], ($attachment['is_image'] ? ', ' . $attachment['real_width'] . 'x' . $attachment['real_height'] . ' - ' . $txt['attach_viewed'] : ' - ' . $txt['attach_downloaded']) . ' ' . $attachment['downloads'] . ' ' . $txt['attach_times'] . '.) ';
}
}
echo '
';
// Show "« Last Edit: Time by Person »" if this post was edited.
if ($settings['show_modify'] && !empty($message['modified']['name']))
echo '
« ', $txt[211], ': ', $message['modified']['time'], ' ', $txt[525], ' ', $message['modified']['name'], ' »';
echo '
';
// Maybe they want to report this post to the moderator(s)?
if ($context['can_report_moderator'])
echo '
', $txt['rtm1'], ' ';
echo '
';
// Show the IP to this user for this post - because you can moderate?
if ($context['can_moderate_forum'] && !empty($message['member']['ip']))
echo '
', $message['member']['ip'], ' (?) ';
// Or, should we show it because this is you?
elseif ($message['can_see_ip'])
echo '
', $message['member']['ip'], ' ';
// Okay, are you at least logged in? Then we can show something about why IPs are logged...
elseif (!$context['user']['is_guest'])
echo '
', $txt[511], ' ';
// Otherwise, you see NOTHING!
else
echo '
', $txt[511];
echo '
';
// Show the member's signature?
if (!empty($message['member']['signature']) && empty($options['show_no_signatures']))
echo '
', $message['member']['signature'], '
';
echo '
';
}
echo '