'Custom Heading 1',
'column2' => 'Custom Heading 2',
'column3' => 'Custom Heading 3'
// Add more custom headings as needed
];
// Define your SQL query
$sql = "SELECT ac_reg, ac_type, ac_call, TIME_FORMAT(eta,'%H:%i') AS ETA, fuel, in_from, pob_in FROM submitted WHERE DATE(eta) = CURDATE() AND status = 'NEW' ORDER BY eta ASC;"; // Replace with your table name
// Execute the query
$result = $conn->query($sql);
// Check if there are results
if ($result->num_rows > 0) {
// Start HTML table
echo '
';
// Output table headers (assuming column names are known)
$fields = $result->fetch_fields();
foreach ($fields as $field) {
if ($field->name != 'ac_call') {
echo '