$value){ $_m_param = safe_replaceX($value); $_GET[$value]= $_m_param; if(containChangeRow($_m_param) == 1){ echo "
参数不正确
"; header("location:cart.php"); exit; } } foreach($_POST as $key=>$value){ $_m_param = safe_replaceX($value); $_POST[$value]= $_m_param; if(containChangeRow($_m_param) == 1){ echo "
参数不正确
"; header("location:cart.php"); exit; } } foreach($_COOKIE as $key=>$value){ $_m_param = safe_replaceX($value); $_COOKIE[$value]= $_m_param; if(containChangeRow($_m_param) == 1){ echo "
参数不正确
"; header("location:cart.php"); exit; } } switch($_REQUEST['op']){ case 'add': if(!$_SESSION[UserName_S]){ //header("location:./user/login.php?mess=请先登录&backUrl=".getCurUrl()); header("location:./user/login.php?mess=请先登录"); exit; } $result = cart_add(); if($result[0]){ //如果是优惠套餐 if($_SESSION[GIDs_S][0] == $_REQUEST['IDProduct'] || $_SESSION[GIDs_S][0] == $_REQUEST['ptype']){ array_shift($_SESSION[GIDs_S]); if(count($_SESSION[GIDs_S])){ gourl('../group/order2.php'); return; }else{ cart_setGroup(); } } $i = 0; if($_SESSION[iLevel_S] == 0) { $cx_sy = get_cx_sy($_REQUEST['IDProduct']); if($cx_sy['price']) { $urls[$i]['url'] = '/main/domain/index.php'; $urls[$i]['text'] = $cx_sy['label']; $urls[$i]['class'] = 'a_tj'; } } $urls[++$i][url] = '/index.php'; $urls[$i][text] = '继续购物'; $urls[++$i][url] = 'cart.php'; $urls[$i][text] = '提交购物车(下一步)'; $result_msg = cart_showmsg(1, $result[1], $urls); }else{ $urls[0][url] = 'javascript:history.back()'; $urls[0][text] = '返回'; $urls[1][url] = 'cart.php'; $urls[1][text] = '查看购物车'; /* $urls[1][url] = 'cart.php'; $urls[1][text] = '提交购物车'; */ $result_msg = cart_showmsg(0, $result[1], $urls); } break; case 'del': cart_del($cartid); $result_msg = cart_list(); break; case 'clear': cart_clear(); $result_msg = cart_list(); break; case 'chg_cxcode': $result = cart_chg_cxcode($cxcode); if(!$result[0]){ $urls[0][url] = 'cart.php'; $urls[0][text] = '返回购物车'; $result_msg = cart_showmsg(0, $result[1], $urls); }else{ $result_msg = cart_list(); } break; case 'post': $result = cart_post(); if(!$result[0]) { if(!$result[2]){ $urls[0][url] = 'cart.php?op=post'; $urls[0][text] = '重试'; $urls[1][url] = 'javascript:history.back()'; $urls[1][text] = '返回'; $urls[2][url] = 'cart.php'; $urls[2][text] = '提交购物车'; }else $urls = $result[2]; $result_msg = cart_showmsg(0, $result[1], $urls); }else { $OrderNo = $result[1]; $key = getHashKey($OrderNo); $urls[0][url] = "gopay.php?OrderNo=$OrderNo&key=$key"; $urls[0][text] = "交费开通"; //$urls[1][url] = '../pay/pay.php?IDFinancial='.$result[2][1]; //$urls[1][text] = '网上支付'; $urls[1][url] = 'fin_in.php'; $urls[1][text] = '网上支付'; $urls[2][url] = '/main/aboutus/paytype.php'; $urls[2][text] = '交费方式'; $urls[2][target] = '_blank'; $result_msg = cart_showmsg(1, "订单提交成功!", $urls); } break; default: $result_msg = cart_list(); } ?> 中国万维网--会员中心

您的位置: 首页 > 会员中心 > 购物车