The row won't delete in my database. I don't know what's wrong TT but then again, I don't have any knowledge in Database.
Here is the code for my delete query:
require_once('connect.php');
$sql_delete="DELETE FROM test WHERE pid='$pid'";
$qry_delete = mysql_query($sql_delete);
and here is the code in PHP. When the user clicks on DELETE, it will automatically delete the selected row. Please help.
while($data = mysql_fetch_array($qry)){
$html .= '<tr align="center">';
$html .= '<td>';
$html .= '<a href="updateprocess.php">Update</a> | <a href="deleteprocess.php">Delete</a>';
$html .= '</td>';
$html .= '<td>';
$html .= $data['pname'];
$html .= '</td>';
$html .= '</tr>';
}
edit: should I change the "pid=$pid" to pname=pname? edit2: pid and pname are fields in my database.