hi,
I have a table which contains fname,lname and email addres and dynamically added check box field too.
Once i checked the check box and then press delete button the relevent record should be deleted.
I tried as follows.<?php
if(isset($_POST[''deleteAcc'']))//delete button
{
$getEmail = "SELECT * FROM user";
$getEmailResult = mysql_query($getEmail);
while($r = mysql_fetch_array($getEmailResult))
{
$email = $r[''email''];
if(isset($_POST[$email])!=NULL)//check box
{
$deleteUserQuery = "DELETE FROM user WHERE email=''$email''";
$deleteUserQueryResult = mysql_query($deleteUserQuery);
header(''Location:admin.php'');
}
}
}
?>
above code will properly work when email something like ''abc''.but it does not work when email like ''a@b.c''.
help me!
thank you.
解决方案_POST[''deleteAcc'']))//delete button
{
getEmail = "SELECT * FROM user";
getEmailResult = mysql_query(