The specified statement cannot be deleted. it is always strange to delete it from the last one. [code = PHP] [/code] formid = & quot; form1 & quot; name = & quot; form1 & quot; method = & quot; post & quot; action = & quot; li cannot delete the specified statement. it's always strange to delete it from the last one.
[Code = PHP] [/code]
Form id = "form1" name = "form1" method = "post" action = "lianxi_ OK .php">
QQ |
Phone Number |
Address |
Author |
Delete |
Include ("../conn. php ");$ Arr = mysql_query ("select * from lianxi", $ conn); // query data/* Use the while statement to loop through the array returned by the mysql_fetch_array () function */While ($ result = mysql_fetch_array ($ arr )){?>
|
|
|
|
"> Edit
|
} // End the while loop?>
------ Solution --------------------
PHP code
Include (".. /conn. php "); // contains conn. php file if (isset ($ _ GET ['id']) {$ delete = mysql_query ("delete from lianxi where id = '". $ _ GET ['id']. "'", $ conn); if ($ delete) {echo "script alert (' deleted successfully! '); Window. location. href = 'index. php' script ";} else {echo" script alert ('deletion failed! '); Window. location. href = 'index. php' script ";}