Return to Snippet

Revision: 32336
at September 22, 2010 21:07 by shawntysco


Initial Code
//Delete
function delete($table, $value){
  $delete_sql = querys("DELETE FROM " . $table . " WHERE id = '" . $value . "';");
}//end delete

//To use:
$del = delete("quick_links", $_GET['id']) ;

Initial URL
linkdeo.net

Initial Description
Used to delete rows from the database. \r\nTo use:\r\n$del = delete(\"quick_links\", $_GET[\'id\']) ;

Initial Title
PHP, Build a basic dynamic  DELETE string

Initial Tags
mysql, php

Initial Language
PHP