Hey guys I keep getting an error on my Update form and it's driving me nuts. I can't figure out where it's at? Any help would be appreciated.
<?php
include 'connect.php';
?>
<form action = 'updateclient.php' method= 'post'>
Select an ID: <input type="text" name="id"><br>
Update Name: <input type="text" name="name"><br>
Update Phone: <input type= "text" name ="phone"><br>
Update Email: <input typer = "text" name="email"><br>
<input type="submit" value="Submit">
</form>
<?php
$sql = "UPDATE Client SET name ='".$_POST['name']."',phone='".$_POST['phone']."',email ='".$_POST['email']."'" ;
$sql.= "WHERE ID = '"$_POST['id']"'";
$result = @mysqli_query($connect,$sql);
?>
@
and ask a question. Check for errors. This code is wide open for a SQL injection.. – chris85 Dec 7 '15 at 1:55Ahhhhh gotcha. I see. Yes this works.
soo the answer works but you don't accept? You followed up later and asked an additional question I followed up on that twice with no response from you. – chris85 Dec 7 '15 at 2:54