Location: PHPKode > projects > TherapyDoc > therapydoc_1.3.1_3/view/referrals/edit_referral.php
<?php
require_once "connect.inc";
include('globals.inc');
$date = isset($_REQUEST["date"]) ? $_REQUEST["date"] : "";
$birthdate = isset($_REQUEST["birthdate"]) ? $_REQUEST["birthdate"] : "";
$sql="UPDATE `tbl_referral_info` SET physician_id=:physician_id,fname=:fname,lname=:lname,date=:date,add1=:add1,add2=:add2,city=:city,state=:state,zip=:zip,phone=:phone,existing=:existing,birthdate=:birthdate,pt=:pt,ot=:ot,st=:st,location_id=:location_id,email=:email,payor1=:payor1,payor2=:payor2 WHERE referral_id=:referral_id";
$stmt = $dbh->prepare($sql);
$stmt->bindParam(':physician_id', $_POST['physician_id']);
$stmt->bindParam(':fname', $_POST['fname']);
$stmt->bindParam(':lname', $_POST['lname']);
$stmt->bindParam(':date', $date);
$stmt->bindParam(':add1', $_POST['add1']);
$stmt->bindParam(':add2', $_POST['add2']);
$stmt->bindParam(':city', $_POST['city']);
$stmt->bindParam(':state', $_POST['state']);
$stmt->bindParam(':zip', $_POST['zip']);
$stmt->bindParam(':phone', $_POST['phone']);
$stmt->bindParam(':existing', $_POST['existing']);
$stmt->bindParam(':birthdate', $birthdate);
$stmt->bindParam(':pt', $_POST['pt']);
$stmt->bindParam(':ot', $_POST['ot']);
$stmt->bindParam(':st', $_POST['st']);
$stmt->bindParam(':location_id', $_POST['location_id']);
$stmt->bindParam(':email', $_POST['email']);
$stmt->bindParam(':payor1', $_POST['payor1_id']);
$stmt->bindParam(':payor2', $_POST['payor2_id']);
$stmt->bindParam(':referral_id', $_POST['referral_id']);
$stmt->execute();

?>
<META
	HTTP-EQUIV="refresh"
	content="0;URL=edit_form.php?referral_id=<?php echo $_POST['referral_id']; ?>&&ed=2">
Return current item: TherapyDoc