|
 |
|
ต้องการความช่วยเหลือจากผู้รู้ทุกๆท่านครับ ถ้าผมต้องการตัดสต๊อก ติดหยุดที่เดียว รบกวนช่วยหน่อยคับ |
|
 |
|
|
 |
 |
|
ลืมเพิ่ม code ตัวดึงฐานข้อมูล คือโค้ดตัวนี้ครับ
Code (PHP)
<?
@session_start();
ob_start();
if(empty($usermem))
//if(empty($_SESSION['usermem']))
{
echo "<script language='javascript'>alert('กรุณาลงทะเบียนก่อนครับ');</script>";
echo "<meta http-equiv='refresh' content='0;URL=Login.php'>";
}else{
$id_product = $_GET[PrdID];
session_register("sess_idproduct");
session_register("sess_name_prd");
session_register("sess_price");
session_register("sess_num");
$today = date("d-m-Y");
if (count($sess_idproduct)=="0") {
$check=1;
} else if (!in_array($id_product, $sess_idproduct)) {
$check=1;
}
if ($check==1) {
include "include/config.inc.php";
$sql="select * from products where id='$id_product' ";
$result=mysql_db_query($db,$sql);
$rs=mysql_fetch_array($result);
$sess_idproduct[]=$rs[productscode];
$sess_name_prd[]=$rs[productsname];
$sess_price[]=$rs[productsprice];
$sess_num[]=1;
}
header("Location: Cart.php");
}
?>
|
 |
 |
 |
 |
Date :
2013-04-11 01:58:03 |
By :
donkey |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
ไม่มีใครเเนะนำเลย....
|
 |
 |
 |
 |
Date :
2013-04-11 19:13:39 |
By :
donkey |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|
|

|
Load balance : Server 01
|