Esempio n. 1
0
$endNum = $startNum + $PREFS->itemsPerPage;
if ($endNum > $itemsNum) {
    $endNum = $itemsNum;
}
$legendRight .= " [ " . ($startNum + 1) . "-" . $endNum . " " . _From . " " . $itemsNum . " ]";
if ($itemsNum == 0) {
    $legendRight = "[ 0 ]";
}
if (0) {
    echo "<div class='tableTitle'>\n\t<div class='titleDiv'>{$legend}</div>\n\t<div class='pagesDiv' style='white-space:nowrap'>{$legendRight}</div>\n\t</div>";
}
if (INLINE_VIEW != 1) {
    require_once dirname(__FILE__) . "/MENU_second_menu.php";
    echo "<div class='list_header'>\n\t\t\t\t<div class='list_header_r'></div>\n\t\t\t\t<div class='list_header_l'></div>\n\t\t\t\t<h1>{$legend}</h1>\n\t\t\t\t<div class='pagesDiv'>{$legendRight}</div>\n\t\t\t</div>";
}
listFlights($res, $legend, $queryExtraArray, $sortOrder);
//P.Wild 15.12.2008
if (INLINE_VIEW != 1) {
    echo "<div class='list_header list_header_bottom'>\n\t\t\t\t<div class='list_header_r list_header_r_bottom'></div>\n\t\t\t\t<div class='list_header_l list_header_l_bottom'></div>\n\t\t\t\t<h1>{$legend}</h1>\n\t\t\t\t<div class='pagesDiv'>{$legendRight}</div>\n\t\t\t</div>";
}
?>
<style type="text/css">
TR .newDate {
	background-image:url(<?php 
echo $themeRelPath;
?>
/img/bg_row.gif);
	background-repeat:repeat-x;
}

.checkedBy1 , td.checkedBy1 , div.checkedBy1{
Esempio n. 2
0
$startNum = ($page_num - 1) * $PREFS->itemsPerPage;
$pagesNum = ceil($itemsNum / $PREFS->itemsPerPage);
if ($pilotID >= 0) {
    $query = "SELECT * ,{$flightsTable}.ID as ID FROM {$flightsTable}," . $prefix . "_users" . $extra_table_str . "  WHERE " . $flightsTable . ".userID=" . $prefix . "_users.user_id " . $where_clause . " ORDER BY " . $sortOrderFinal . " " . $ord . " LIMIT {$startNum}," . $PREFS->itemsPerPage;
} else {
    $query = "SELECT * ,{$flightsTable}.ID as ID FROM {$flightsTable} " . $extra_table_str . "  WHERE (1=1) " . $where_clause . " ORDER BY " . $sortOrderFinal . " " . $ord . " LIMIT {$startNum}," . $PREFS->itemsPerPage;
}
//  echo $query;
$res = $db->sql_query($query);
if ($res <= 0) {
    echo "<H3> Error in query! </H3>\n";
    exit;
}
//  $legend.=_SORTED_BY." ".$sortDesc;
$legend .= "<img src='{$moduleRelPath}/img/icon_sort.png' border=0 align=absmiddle>&nbsp;" . replace_spaces($sortDesc);
listFlights($res, $legend, $query_str, $sortOrder);
function printHeader($width, $headerSelectedBgColor, $headerUnselectedBgColor, $sortOrder, $fieldName, $fieldDesc, $query_str)
{
    global $moduleRelPath;
    global $Theme, $module_name;
    if ($width == 0) {
        $widthStr = "";
    } else {
        $widthStr = "width='" . $width . "'";
    }
    if ($sortOrder == $fieldName) {
        echo "<td {$widthStr} bgcolor='{$headerSelectedBgColor}'>\n\t\t<div class='whiteLetter' align=left>\n\t\t<a href='?name={$module_name}&op=list_flights&sortOrder={$fieldName}{$query_str}'>{$fieldDesc}<img src='{$moduleRelPath}/img/icon_arrow_down.png' border=0  width=10 height=10></div></td>";
    } else {
        echo "<td {$widthStr} bgcolor='{$headerUnselectedBgColor}'>\n\t\t<div align=left>\n\t\t<a href='?name={$module_name}&op=list_flights&sortOrder={$fieldName}{$query_str}'>{$fieldDesc}</div></td>";
    }
}