Cant get it to delete
Posted: Tue Oct 20, 2009 1:30 pm
I have a page that lists the user and has an option to delete the record. But I can not get it to delete the record. I believe that I am passing the correct information but it just will not delete. It just goes to delete.php and displays a blank name. The pop up that I have before it switches pages post the correct info. Where am I going wrong?
delete.php
Code: Select all
->addColumnAfter('actions', '<a href="#edit.php?id=$user_id$">Edit</a>
- <a href="delete.php?id=$id_user$" onclick="return confirm(\'Are you sure you want to delete user $id_user$?\')">Delete</a>
', 'Actions', array('align' => 'center'))
Code: Select all
<php
include 'dbc.php';
$id_user = $_GET[id];
echo $id_user;
echo "<br>";
echo $id;
mysql_query("Delete From users where id_user = $id_user");
?>