".$row["name"]." | "; $cars[$row["name"]]=$row["name"]; } while ($row = @ mysql_fetch_array($result_bookings)) { $starttime = strtotime($row["start"]); $endtime = strtotime($row["end"]); for ($i = 0; $i < $interval; $i++) { $mytime = strtotime("$firstday + $i days"); if ($mytime >= $starttime && $mytime < $endtime) { $user[$row["name"]][$i] = substr($row["first_name"],0,1).". ".$row["user"]; $email[$row["name"]][$i] = $row["e_mail"]; $bid[$row["name"]][$i] = $row["bid"]; } } } for ($i = 0; $i < $interval; $i++) { echo "||
---|---|---|
". date("D d.m.Y",strtotime("$firstday + $i days"))." | "; foreach ($cars as $r) { if ($user[$r][$i] != "") echo "".$user[$r][$i]." | "; else echo ""; } echo " |
test ${data} | "; # } # echo "
From | Till | Person | Car | 0) echo "Move to | "; ?> Change booking"; ?>$row[start] | $row[end] | $row[first_name] $row[user] | $row[name] | EOT; if (count($car_own) > 0) { $r1 = min(max(0, $row[r1]),$interval); $r2 = min(max(0, $row[r2]-1),$interval); echo "";
foreach ($car_own as $car_id => $car_name) {
echo << | ";
if (preg_match("/sadmin/", $_SESSION["role"]) != 0) {
echo "Unbook | "; } } echo ""; } ?>
---|
From | Till | Name | Comment | 0) echo "Accept for | "; if (preg_match("/admin/", $_SESSION["role"]) != 0) echo "Admin | "; ?> "; echo "$row[start] | "; echo "$row[end] | "; echo "$row[first_name] $row[name] | "; echo "$row[comment] | "; if (count($car_own) > 0) { echo "";
$r1 = min(max(0, $row[r1]),$interval);
$r2 = min(max(0, $row[r2]-1),$interval);
foreach ($car_own as $car_id => $car_name) {
echo << | ";
}
if ((preg_match("/admin/", $_SESSION["role"]) != 0) ||
(preg_match("/caradmin/", $_SESSION["role"]))) {
echo "";
echo "Reject "; echo ""; echo " | ";
}
echo "";
}
?>
---|