Location: PHPKode > projects > Pet Grooming Management System > pet/changeCompany3.php
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">

<title>PGMS Modify Company Page 3</title>
$cid = $_POST['cid'];
$cname = $_POST['cname'];
$address = $_POST['address'];
$city = $_POST['city'];
$st = $_POST['st'];
$zip = $_POST['zip'];
$phone = $_POST['phone'];
$fax = $_POST['fax'];
$tax = $_POST['tax'];
$tax = $tax/100;

<link rel="stylesheet" type="text/css"
href="background.css" />
require ('header.inc');
require ('info.inc');
$link = mysql_connect('localhost',$r,$p) or die("Could not connect to Host.");
mysql_select_db($d) or die("Could not select database.");
$query = "UPDATE companies SET name = '$cname', address = '$address', city='$city',st='$st',zip='$zip',phone='$phone',fax='$fax',tax=$tax
          where cid = '$cid'";
$result = mysql_query($query);
	 if (mysql_affected_rows()==1){
	     echo '<P>The Company has been updated. You will be directed to the manage users page in 10 seconds';
			 echo '<P>Something went wrong with your update company attempt.</P>';
Return current item: Pet Grooming Management System