kleeja_admin_err($lang['DELETE_PROCESS_IN_WORK'], true, $lang['ERROR'], true, basename(ADMIN_PATH) . '?cp=' . basename(__FILE__, '.php'), 1); } else { update_config('queue', $config['queue'] . ':' . $current_smt . 'reports:'); kleeja_admin_info($lang['DELETE_PROCESS_QUEUED'], true, '', true, basename(ADMIN_PATH) . '?cp=' . basename(__FILE__, '.php')); } } $query = array('SELECT' => '*', 'FROM' => "{$dbprefix}reports r", 'ORDER BY' => 'r.id DESC'); if ($current_smt == 'show_h24') { $query['WHERE'] = 'r.time > ' . intval(time() - 3600 * 24); } $result = $SQL->build($query); //pagination $nums_rows = $SQL->num_rows($result); $currentPage = isset($_GET['page']) ? intval($_GET['page']) : 1; $Pager = new SimplePager($perpage, $nums_rows, $currentPage); $start = $Pager->getStartRow(); $no_results = false; $del_nums = array(); if ($nums_rows > 0) { $query['LIMIT'] = "{$start}, {$perpage}"; $result = $SQL->build($query); while ($row = $SQL->fetch_array($result)) { //make new lovely arrays !! $arr[] = array('id' => $row['id'], 'name' => $row['name'], 'mail' => $row['mail'], 'url' => $row['url'], 'text' => $row['text'], 'human_time' => kleeja_date($row['time']), 'time' => kleeja_date($row['time'], false), 'ip' => $row['ip'], 'sent' => $row['id'] == $msg_sent, 'ip_finder' => 'http://www.ripe.net/whois?form_type=simple&full_query_string=&searchtext=' . htmlspecialchars($row['ip']) . '&do_search=Search'); $del[$row['id']] = isset($_POST['del_' . $row['id']]) ? $_POST['del_' . $row['id']] : ''; $sen[$row['id']] = isset($_POST['v_' . $row['id']]) ? $_POST['v_' . $row['id']] : ''; //when submit !! if (isset($_POST['submit'])) { if ($del[$row['id']]) { $del_nums[] = $row['id']; }