How hot is Jarrod?

"; $sql = "select reading$x, serverRecievedDate, voltage$x from smartsense.bubbas1 where idSite = 3 and reading$x != -2 and voltage$x != -2 ORDER BY idReading desc limit 1;"; echo (""); $result = database::dbQuery($sql); if ($result->num_rows == 1) { $row = $result->fetch_row(); //print_r($row); echo ""; //Date Processing $phpdate = new DateTime( $row[1] ); $now = new DateTime('NOW'); $phpdate->add(new DateInterval('PT600S')); // echo "NOW " . $now->format('Y-m-d H:i:s') . "SENSE " . $phpdate->format('Y-m-d H:i:s') . ""; if ($phpdate < $now) echo ""; else echo ""; echo ""; } else { echo ""; } echo ""; } ?>
Sensor Temperature Last Update Voltage
$x$row[0]
$row[1]$row[1]$row[2]Sensor Offline

* Sensors will be marked red if connectivity is lost for 600s (10 mins)
* Voltages down to 2.823 have so far proven reliable