Snow Conditions

connect_error) { die("Connection failed: " . $conn->connect_error); } $today = date("Y-m-d"); $today2 = date("D. M. d/y"); //$sql = "SELECT id, first/name, lastname FROM MyGuests"; //$query = "SELECT Amount, Resort FROM Snowfall WHERE Date = 2016-11-19"; $sql = "SELECT * FROM Snowfall WHERE Date = '$today' ORDER BY YearToDate DESC"; $result = $conn->query($sql); print ( "
". "

Snow Conditions for ". $today2."

". "
". "
RESORT
". "
". "
24 HRS
". "
48 HRS
". "
WEEK
". "
PACKED BASE
". "
YEAR TO DATE
". "
". "
" ); if ($result->num_rows > 0) { // output data of each row while($row = $result->fetch_assoc()) { $onedw = $row["Amount"]*1; $twodw = $row["FortyEightHour"]*1.05; $weekw = $row["SevenDay"]*1.1; $basew = $row["BasePacked"]*1; $yrtdw = $row["YearToDate"]*1.02; print ( "
". "
".$row["Resort"]."
". "
". "
".$row["Amount"]."
". "
".$row["FortyEightHour"]."
". "
".$row["SevenDay"]."
". "
".$row["BasePacked"]."
". "
".$row["YearToDate"]."
". "
". "
" ); } } print ( "
" ); $conn->close();