I have a problem with my php code.so This is my form written in a php page:
echo "<form action='strg_cont.php' method=\"post\">
<input type=\"hidden\" name=\"name\" value=".$info['email'] .">
<input type=\"submit\" name=\"submit\" value=\"Delete\">
</form> "
And this is my read strg_cont.php code:
<?php session_start();
if(isset($_POST['email'])) {
$myEmail = $_POST['email'];
$servername = "localhost";
$username="root";
$conn = @mysql_connect($servername,$username) or die(mysql_error());
mysql_select_db("db_onco",$conn);
$emailPentruSterge = mysql_real_escape_string($contact_name);
$verifica_exista_email = mysql_query("SELECT * FROM contacte WHERE email = '$emailPentruSterge'");
..............
}
?>
Why in my str_cont.php code $_POST['email'] is blank and if block is not "executed"? I don't read correct information or what problem i have?
Thanks.
mysqlit's deprecated, parametrized queries are safer and all that.