update recoords in a database
I am trying to setup my pages to update records in my database with no success.
The script I have at the moment is
<?php
if ($_SERVER["REQUEST_METHOD"] == "POST") {
$UpdateQuery = new WA_MySQLi_Query($Lets4u_i);
$UpdateQuery->Action = "update";
$UpdateQuery->Table = "lets4u";
$UpdateQuery->bindColumn("id", "s", "".((isset($_POST["id"]))?$_POST["id"]:"") ."", "WA_DEFAULT");
$UpdateQuery->bindColumn("rooms", "i", "".((isset($_POST["rooms"]))?$_POST["rooms"]:"") ."", "WA_DEFAULT");
$UpdateQuery->addFilter("id", "=", "i", "".((isset($_POST["id"]))?$_POST["id"]:"") ."");
$UpdateQuery->execute();
$UpdateGoTo = "manage_house.php";
if (function_exists("rel2abs")) $UpdateGoTo = $UpdateGoTo?rel2abs($UpdateGoTo,dirname(__FILE__)):"";
$UpdateQuery->redirect($UpdateGoTo);
}
?>
Help Appreciated