<?php
$dsn = "mysql:host=localhost;dbname=baza";
$user = "username";
$passwd = "pass";
$datetoday = date('Y-m-d');
$pdo = new PDO($dsn, $user, $passwd);
$stm = $pdo->query("SELECT * FROM bookings WHERE date='$datetoday' ORDER BY timeslot");
$rows = $stm->fetchAll(PDO::FETCH_ASSOC);
// Prikazivanje knjiga
foreach ($rows as $vozilo)
{
echo "<tr>";
echo " <td>{$vozilo['timeslot']}</td>";
echo " <td>{$vozilo['marka']}</td>";
echo " <td>{$vozilo['telefon']}</td>";
echo " <td>{$vozilo['date']}</td>";
echo " <td>{$vozilo['timeslot']}</td>";
echo " <td>{$vozilo['klijent']}</td>";
echo "</tr>";
}
?>