Delete data from database table : Database Delete : MySQL Database PHP Source Code


PHP Source Code » MySQL Database » Database Delete »

 

Delete data from database table




<?php
   mysql_connect("mysql153.secureserver.net","navioo","password");
   mysql_select_db("navioo");

   $rowID = "001";
   $query = "DELETE FROM Employee WHERE ID='$rowID'";
   $result = mysql_query($query);

   if ((mysql_affected_rows() == 0|| mysql_affected_rows() == -1) {
        echo "<p>There was a problem deleting some of the selected items.</p>";
        exit;
   }
?>

           
       



HTML code for linking to this page:

Follow Navioo On Twitter

PHP Source Code

 Navioo MySQL Database
» Database Delete