|
|
|
update ข้อมูลไม่ได้ครับ ช่วยดูโค๊ดหน่อยครับ พยายามแก้หลายรอบแล้วครับ |
|
|
|
|
|
|
|
<?
include ("include/connect.php");
$com_id = $_POST['com_id'];
$brand_com = $_POST['brand_com'];
$cpu_com = $_POST['cpu_com'];
$mainboard_com = $_POST['mainboard_com'];
$ram_com = $_POST['ram_com'];
$hdd_com = $_POST['hdd_com'];
$vga_com = $_POST['vga_com'];
$asset_com = $_POST['asset_com'];
$serail_com = $_POST['serial_com'];
$brand_monitor = $_POST['brand_monitor'];
$serail_monitor = $_POST['serial_monitor'];
$asset_monitor = $_POST['asset_monitor'];
$ipaddress = $_POST['ipaddress'];
$segment = $_POST['segment'];
$user = $_POST['user'];
$sql = " update computer set
brand_com = '$brand_com',
cpu_com = '$cpu_com',
mainboard_com = '$mainboard_com',
ram_com = '$ram_com',
hdd_com = '$hdd_com',
vga_com = '$vga_com',
asset_com = '$asset_com',
serial_com = '$serial_com',
brand_monitor = '$brand_monitor',
serial_monitor = '$serial_monitor',
asset_monitor= '$asset_monitor',
ipaddress = '$ipaddress',
segment ='$segment',
user = '$user'
where com_id = '$com_id' ";
mysql_query($sql) or die ("error=$sql");
echo "<script>alert ('แก้ไขข้อมูลเรียบร้อยแล้ว'); window.location = '/shservice/search5.php';</script>";
?>
<title>SH-Service</title>
Tag : PHP
|
|
|
|
|
|
Date :
2013-01-11 21:42:04 |
By :
เอก |
View :
822 |
Reply :
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
ลอง Echo ตัวแปล $sql แล้วลองเอาไปแปะดูที่ phpMyadmin ก็ได้ครับ
|
|
|
|
|
Date :
2013-01-11 22:09:41 |
By :
Manussawin |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
or die(mysql_error()); แล้วเอา error มาดู ถ้าไม่มีก็ให้ echo sql มาดูครับ
|
|
|
|
|
Date :
2013-01-11 22:56:48 |
By :
mr.win |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Load balance : Server 01
|