PHP form issue , reading from a form issue -
i have problem php code.so form written in 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 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 * contacte email = '$emailpentrusterge'"); .............. } ?>
why in str_cont.ph
p code $_post['email'
] blank , if block not "executed"? don't read correct information or problem have? thanks.
<input type=\"hidden\" name=\"name\" value=".$info['email'] .">
means $_post['name']
sent, not $_post['email']
.
change to
<input type=\"hidden\" name=\"email\" value=".$info['email'] .">
Comments
Post a Comment