} } // Redirect redirect('inbox.php'); } else { $page_title = array(luna_htmlspecialchars($luna_config['o_board_title']), __('Delete message', 'luna')); define('FORUM_ACTIVE_PAGE', 'pm'); require load_page('header.php'); // If you're not the owner of the message, you can't delete it. $result = $db->query('SELECT owner, show_message, posted, sender, message, hide_smilies FROM ' . $db->prefix . 'messages WHERE id=' . $mid) or error('Unable to delete the message', __FILE__, __LINE__, $db->error()); $cur_delete = $db->fetch_assoc($result); if ($cur_delete['owner'] != $luna_user['id'] && !$luna_user['is_admmod']) { message(__('You do not have permission to access this page.', 'luna')); } $cur_delete['message'] = parse_message($cur_delete['message']); load_inbox_nav($page); require load_page('inbox-delete-post.php'); require load_page('footer.php'); } } else { // Start building page $result_receivers = $db->query('SELECT DISTINCT receiver, owner, sender_id FROM ' . $db->prefix . 'messages WHERE shared_id=' . $tid) or error('Unable to get the informations of the message', __FILE__, __LINE__, $db->error()); if (!$db->num_rows($result_receivers)) { message(__('Bad request. The link you followed is incorrect, outdated or you are simply not allowed to hang around here.', 'luna')); } $owner = array(); while ($receiver = $db->fetch_assoc($result_receivers)) { $r_usernames = $receiver['receiver']; $owner[] = $receiver['owner']; $uid = $receiver['sender_id']; }
<?php // Make sure no one attempts to run this view directly. if (!defined('FORUM')) { exit; } load_inbox_nav('view'); echo $paging_links; draw_response_list(); echo $paging_links; ?> <!-- <form method="post" id="post" action="new_inbox.php?reply=<?php echo $tid; ?> " onsubmit="return process_form(this)"> <?php draw_editor('10'); ?> </form> -->
<?php // Make sure no one attempts to run this view directly. if (!defined('FORUM')) { exit; } load_inbox_nav('send'); // If there are errors, we display them if (!empty($errors)) { ?> <div class="panel panel-danger"> <div class="panel-heading"> <h3 class="panel-title"><?php _e('Post errors', 'luna'); ?> </h3> </div> <div class="panel-body"> <?php foreach ($errors as $cur_error) { echo "\t\t\t\t" . $cur_error . "\n"; } ?> </div> </div> <?php } elseif (isset($_POST['preview'])) { require_once FORUM_ROOT . 'include/parser.php'; $preview_message = parse_message($p_message); ?> <div class="panel panel-default">
echo luna_htmlspecialchars($luna_user['username']); ?> </h3> <span class="user-card-avatar thumbnail"> <?php echo $avatar_user_card; ?> </span> </div> <?php load_me_nav('inbox'); ?> </div> <div class="col-sm-9 profile"> <?php load_inbox_nav('inbox'); ?> <p><span class="pages-label"><?php echo paginate($num_pages, $page, 'inbox.php?'); ?> </span></p> <form method="post" action="inbox.php"> <fieldset> <div class="btn-toolbar"> <div class="btn-group"> <button type="submit" name="markread" class="btn btn-primary"><span class="fa fa-fw fa-eye"></span> <?php _e('Mark as read', 'luna'); ?> </button> <button type="submit" name="markunread" class="btn btn-primary"><span class="fa fa-fw fa-eye-slash"></span> <?php _e('Mark as unread', 'luna');