<?php session_start(); include "../functions.inc.php"; $rkeys = array_keys($_GET); $CONF['title_header'] = lang('TICKET_name') . " #" . get_ticket_id_by_hash($rkeys[1]) . " - " . $CONF['name_of_firm']; if (validate_user($_SESSION['helpdesk_user_id'], $_SESSION['code'])) { include "head.inc.php"; include "navbar.inc.php"; //echo $rkeys[1]; //$hn=($_GET['hash']); $hn = $rkeys[1]; $stmt = $dbConnection->prepare('SELECT id, user_init_id, user_to_id, date_create, subj, msg, client_id, unit_id, status, hash_name, comment, last_edit, is_read, lock_by, ok_by, arch, ok_date, prio, last_update from tickets where hash_name=:hn'); $stmt->execute(array(':hn' => $hn)); $res1 = $stmt->fetchAll(); if (!empty($res1)) { foreach ($res1 as $row) { $lock_by = $row['lock_by']; $ok_by = $row['ok_by']; $ok_date = $row['ok_date']; $cid = $row['client_id']; $tid = $row['id']; $arch = $row['arch']; $status_ok = $row['status']; if ($arch == 1) { $st = "<span class=\"label label-default\"><i class=\"fa fa-archive\"></i> " . lang('TICKET_status_arch') . "</span>"; } if ($arch == 0) {
echo $row['id']; ?> </center></small></td> <td><small><?php echo get_file_icon($row['file_hash']); ?> <?php echo $row['original_name']; ?> </small></td> <td><small><a href="./ticket?<?php echo $row['ticket_hash']; ?> ">#<?php echo get_ticket_id_by_hash($row['ticket_hash']); ?> </a></small></td> <td><small><?php echo round($row['file_size'] / (1024 * 1024), 2); ?> Mb</small></td> <td><small><center> <button id="files_del" type="button" class="btn btn-danger btn-xs" value="<?php echo $row['file_hash']; ?> " title="<?php echo lang('FILES_del'); ?> "><i class="fa fa-trash-o"></i> </button> <a href="<?php