<?
$db = "1book";
$table = "_info";

$link = mysql_connect("localhost","root","pass") or die("Couldn't connect to MySQL");

mysql_select_db($db , $link) or die("Couldn't open $db: ".mysql_error());

mysql_query("UPDATE $table SET home='31234' WHERE id='1'");

echo "Record Updated";

mysql_close($link);
?>
Published in: MySQL
Download

Related snippets