<?php
$submit = $_POST["submit"];
if ($submit) {
$username = $_POST["username"];
$comment = $_POST["comment"];
$connection = mysql_connect("localhost", "****", "****") or die("connect");
mysql_select_db("****",$connection) or die ("Unable to select requested database.");
$changeresult = mysql_query
("UPDATE `auth` SET `comm` = $comment WHERE `username` = $username");
$result=mysql_query($changeresult, $connection);
$affected_rows=mysql_affected_rows($connection);
echo "<b>$username</b> was affected.";
}
?>
This code goes to the last line successfuly but the "UPDATE" does not occur I have tried various ways of writing this code. Can anyone show me a solution or point me in the right direction.