Exemple #1
0
        $hint = "<div class='header'><strong>{$site_description}</strong></div>";
        if ($description["included"]) {
            $hint .= "<div class='header'><strong>" . NETCAT_MODULE_SEARCH_ADMIN_QUERY_AREA_INCLUDED . "</strong>:</div><div class='list'>";
            foreach ($description["included"] as $item) {
                $hint .= "<div class='item'>" . NETCAT_MODULE_SEARCH_ADMIN_BULLET . " {$item}</div>\n";
            }
            $hint .= "</div>";
        }
        if ($description["excluded"]) {
            $hint .= "<div class='header'><strong>" . NETCAT_MODULE_SEARCH_ADMIN_QUERY_AREA_EXCLUDED . "</strong>:</div><div class='list'>";
            foreach ($description["excluded"] as $item) {
                $hint .= "<div class='item'>" . NETCAT_MODULE_SEARCH_ADMIN_BULLET . " {$item}</div>\n";
            }
            $hint .= "</div>";
        }
        $area_cell = "<td class='area_hint'><div>" . $area->to_string() . "</div>" . "<div class='inline_help area_description'>{$hint}</div>" . "</td>";
    }
    $search_link = nc_search::get_object()->get_search_url($row['Catalogue_ID'], true) . "?nologging=1&amp;search_query=" . rawurlencode($row['QueryString']) . "&amp;area=" . rawurlencode($row['Area']);
    echo "<tr class='nc-text-center'>", "<td>", nc_search_util::format_time($row['Timestamp']), "</td>", $area_cell, "<td><a href='{$search_link}' target='_blank' title='", htmlspecialchars(NETCAT_MODULE_SEARCH_ADMIN_QUERY_OPEN_RESULTS_LINK_HINT), "'>", $row['ResultsCount'], "</a></td>", "<td>", $row['User_ID'] ? $this->hash_link("#user.edit({$row['User_ID']})", $row["Login"]) : "&nbsp;", "</td>", "<td>", long2ip($row['IP']), "</td>", "</tr>\n";
}
$ui = $this->get_ui();
$ui->actionButtons[] = array("id" => "prev_page", "caption" => NETCAT_MODULE_SEARCH_ADMIN_QUERY_BACK_TO_LIST, "location" => "#module.search.queries", "align" => "left");
$page_link = $this->make_page_query(array('offset'), true);
if ($offset > 0) {
    $prev_page = $page_link . "&amp;offset=" . ($offset - $per_page);
    $ui->actionButtons[] = array("id" => "prev_page", "caption" => NETCAT_MODULE_SEARCH_ADMIN_QUERY_PREV_PAGE, "action" => "mainView.loadIframe('{$prev_page}')", "align" => "left");
}
if ($found_rows > $offset + $per_page) {
    $next_page = $page_link . "&amp;offset=" . ($offset + $per_page);
    $ui->actionButtons[] = array("id" => "next_page", "caption" => NETCAT_MODULE_SEARCH_ADMIN_QUERY_NEXT_PAGE, "action" => "mainView.loadIframe('{$next_page}')");
}