By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
429,589 Members | 1,194 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 429,589 IT Pros & Developers. It's quick & easy.

Parse error: syntax error, unexpected '$email'

P: 1
how can id fix this error from this code

<!DOCTYPE html>
<html>
<head>

</head>
<body>

<form method="POST">

<input type="email" name="email" placeholder="email" ><br><br>

<input type="submit" name="Delete" value="Delete">


</form>

</body>
</html>


<?php

require connection.php


$email;
$sqlDelete = "DELETE FROM `users` WHERE `email`= ' ".$email." ' ";

$result = mysql_query($con, $sqlDelete);

if($result) {

echo ('Successfully Deleted');
}
else
{
echo('Not Delete Successfully');
}



?>
4 Weeks Ago #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.