Step by step method to Update a field:
//First the user will specify what field to Update
<form method="post">
<p>Field to Update:
<input type="text" name="pupdate"></p>
//Next the user will update the field
<p>Updated Name:
<input type="text" name="pname"></p>
<p><input type="submit" value="Add New"/></p>
</form>
<?php
//To connect to database(If you dont understand the next line I can explain it further)
require_once "db.php";
if ( isset($_POST['pupdate']) && isset($_POST['pname']))
{
$up = $_POST['pupdate'];
$u = $_POST['pname'];
//This will update the database with the new field
$sql = "UPDATE NAMEOFTABLE
SET pname='$u'
WHERE pname='$up'";
echo "<pre>
$sql
</pre>
";
mysql_query($sql);
}
?>