$floraRowsDeleted = $dbConnection->mysqliObject->affected_rows; // Print out confirmation message. print 'Rows deleted in floratable is ' . $floraRowsDeleted . '<br /><br />'; // Delete all rows in the weather table with the passed in weather id. // SQL statement to gather data. $sqlStatement = "DELETE FROM weathertable\n WHERE weatherid = '{$weatherID}'"; // Call insertUpdateDeleteDatabase function to add new row. $insertUpdateDeleteResult = $dbConnection->insertUpdateDeleteDatabase($sqlStatement); // Confirm insert was done. $weatherRowsDeleted = $dbConnection->mysqliObject->affected_rows; // Print out confirmation message. print 'Rows deleted in weathertable is ' . $weatherRowsDeleted . '<br /><br />'; } // Only do this if successfully connected to the database. if ($connectionResult == 0) { // Call function to close database connection. $closeResults = $dbConnection->closeConnection(); // Print results of function closeConnection(). print $closeResults . '<br /><br />'; } // Only do this if successfully connected to the database. if ($connectionResult == 0) { // Put the include statement in this location only for it to work. // The statement sends the program to this next page. It also still allows access to any // variables on this page. include_once "../Views/Administrative-Menu.php"; } } else { // Print error message. print $_GET["weatherid"] . ' is not a valid Weather ID.' . '<br /><br />'; }