','off'); include("settings/db_ini.php"); include '../include/conf.php'; session_start(); $browsessionid=session_id(); $sessionid_free=$_SESSION["user_id"]; $qua=$_REQUEST['qua']; $menuid=$_REQUEST['menuid']; $prodprice=$_REQUEST['product_price']; $va_country=$_REQUEST['va_country']; $orderid=$_REQUEST['orderid']; $totprice=$qua * $prodprice; $malu_id=$_REQUEST['del_id_mal']; //get the cureent offer units $get_user = mysql_query("select * from shop_user where user_id='$sessionid_free'"); $set_user = mysql_fetch_array($get_user); $new_status = $set_user['new_status']; $get_prod_id = mysql_query("select * from shop_cart_admin where id='$menuid'"); $set_prod_id = mysql_fetch_array($get_prod_id); $get_product = mysql_query("select * from shop_product where product_id = '".$set_prod_id['productid']."'"); $set_product = mysql_fetch_array($get_product); $offer_unit = $set_product['offer_unit']; if($new_status==1 && $set_user['user_id']!='11363') { if($offer_unit=="2+1") { $v_qty=($qua/2); } if($offer_unit=="4+1") { $v_qty=($qua/4); } $x = (int)$v_qty; } else { $x=0; } $ord_fetch = mysql_query("select * from tbl_confiromorder where orderid = '$orderid'"); $ord_fetch_id = mysql_fetch_array($ord_fetch); echo $ord_fetch_id['orderid']; if($qua==0) { $Delete_Question = "DELETE FROM shop_cart_admin WHERE id='$menuid' "; $Result_Question = mysql_query($Delete_Question); } if($malu_id!="") { $Delete_Question = "DELETE FROM shop_cart_admin WHERE id='$malu_id' "; $Result_Question = mysql_query($Delete_Question); } else { $Updatecart = "UPDATE shop_cart_admin SET `qty`='$qua', `qty_free`= '$x', `totprice`='$totprice', `qty_free`='$x' WHERE id='$menuid'"; $Recart = mysql_query($Updatecart); $browsessionid=$_REQUEST['browsessionid']; } $Query_jobmal = mysql_query("SELECT id from shop_cart_admin where session_id='$browsessionid' "); $qty=mysql_num_rows($Query_jobmal); $objqrynewsubee = "SELECT SUM(totprice) AS amtTotal FROM shop_cart_admin where session_id='$browsessionid'"; $objResultnewsubee = mysql_query($objqrynewsubee); $Fetchnewww = mysql_fetch_array($objResultnewsubee); $subtotal=$Fetchnewww['amtTotal']; $dis_amount=0; ?> 0) { while($Fetitem = mysql_fetch_array($objitem)) { $menuid=$Fetitem['id']; $menuid_d_s=$Fetitem['productid']; $si=$si+1; $qty=$Fetitem['qty']; $qty_free=$Fetitem['qty_free']; /*$qty_p=""; $qty_p .="qty_"; $qty_p .=$menuid_d_s; $qty_p; $par=$_REQUEST[$qty_p]; if($par=='') { $qty=1; } if($par=='') { $qty=$par; }*/ $objmenu=mysql_query("SELECT * from shop_product where product_id='$menuid_d_s'"); $resmenu=mysql_fetch_array($objmenu); $menuname=$resmenu['name']; $productprice=$resmenu['price']; $productprice_int=$resmenu['price']; $totprice=($qty*$resmenu['price']); $totprice_int=($qty*$resmenu['price']); $new_price +=$totprice_int; $vstatus=$resmenu['vstatus']; $offer_unit=$resmenu['offer_unit']; $weight=$resmenu['stock_status_id']; if($weight=='' || $weight==0) { $weight=100; } if($new_status==1 && $set_user['user_id']!='11363') { if($offer_unit=="2+1") { $v_qty=($qty/2); } if($offer_unit=="4+1") { $v_qty=($qty/4); } $x = (int)$v_qty; } else { $x=0; } $x; $new_qty=($weight*($qty+$x)); $new_kilo=($new_qty/1000); $new_kilo_1 = explode('.',$new_kilo); $new_kilo_2=$new_kilo_1[0]; // Before the Decimal point $new_kilo_3 +=$new_kilo_2; $totprice1 +=$totprice; $tot_weight_2 +=$new_qty; $Query_job_move_product = mysql_query("SELECT * from shop_product_image where product_id='$menuid_d_s' order by product_id asc "); $row_job_move_product_id = mysql_fetch_array($Query_job_move_product); ?>
0) { ?>
   Product Total
    x 0) { ?> 0) { ?>0) { ?>  
    x .00
   Cart Total
   Weight
   Shipping & Packing Charges .00
   Order Total ( Inclusive of GST )
0) { while($Fetitem = mysql_fetch_array($objitem)) { $menuid=$Fetitem['id']; $menuid_d_s=$Fetitem['productid']; $si=$si+1; $qty=$Fetitem['qty']; $qty_free=$Fetitem['qty_free']; /*$qty_p=""; $qty_p .="qty_"; $qty_p .=$menuid_d_s; $qty_p; $par=$_REQUEST[$qty_p]; if($par=='') { $qty=1; } if($par=='') { $qty=$par; }*/ $objmenu=mysql_query("SELECT * from shop_product where product_id='$menuid_d_s'"); $resmenu=mysql_fetch_array($objmenu); $menuname=$resmenu['name']; $productprice=$resmenu['price']; $productprice_int=$resmenu['price']; $totprice=($qty*$resmenu['price']); $totprice_int=($qty*$resmenu['price']); $new_price +=$totprice_int; $vstatus=$resmenu['vstatus']; $offer_unit=$resmenu['offer_unit']; $weight=$resmenu['stock_status_id']; if($weight=='' || $weight==0) { $weight=100; } if($new_status==1 && $set_user['user_id']!='11363') { if($offer_unit=="2+1") { $v_qty=($qty/2); } if($offer_unit=="4+1") { $v_qty=($qty/4); } $x = (int)$v_qty; } else { $x=0; } $x; $new_qty=($weight*($qty+$x)); $new_kilo=($new_qty/1000); $new_kilo_1 = explode('.',$new_kilo); $new_kilo_2=$new_kilo_1[0]; // Before the Decimal point $new_kilo_3 +=$new_kilo_2; $totprice1 +=$totprice; $tot_weight_2 +=$new_qty; $Query_job_move_product = mysql_query("SELECT * from shop_product_image where product_id='$menuid_d_s' order by product_id asc "); $row_job_move_product_id = mysql_fetch_array($Query_job_move_product); ?>
0) { ?>
   Product Total
    x 0) { ?> 0) { ?>(0) { ?>+ Free  
)
    x .00
   Cart Total
0) { while($Fetitem = mysql_fetch_array($objitem)) { $menuid=$Fetitem['id']; $menuid_d_s=$Fetitem['productid']; $si=$si+1; $qty=$Fetitem['qty']; $qty_free=$Fetitem['qty_free']; /*$qty_p=""; $qty_p .="qty_"; $qty_p .=$menuid_d_s; $qty_p; $par=$_REQUEST[$qty_p]; if($par=='') { $qty=1; } if($par=='') { $qty=$par; }*/ $objmenu=mysql_query("SELECT * from shop_product where product_id='$menuid_d_s'"); $resmenu=mysql_fetch_array($objmenu); $menuname=$resmenu['name']; $productprice=$resmenu['price']; $productprice_int=$resmenu['price']; $totprice=($qty*$resmenu['price']); $totprice_int=($qty*$resmenu['price']); $new_price +=$totprice_int; $vstatus=$resmenu['vstatus']; $offer_unit=$resmenu['offer_unit']; $weight=$resmenu['stock_status_id']; if($weight=='' || $weight==0) { $weight=100; } if($new_status==1 && $set_user['user_id']!='11363') { if($offer_unit=="2+1") { $v_qty=($qty/2); } if($offer_unit=="4+1") { $v_qty=($qty/4); } $x = (int)$v_qty; } else { $x=0; } $x; $new_qty=($weight*($qty+$x)); $new_kilo=($new_qty/1000); $new_kilo_1 = explode('.',$new_kilo); $new_kilo_2=$new_kilo_1[0]; // Before the Decimal point $new_kilo_3 +=$new_kilo_2; $totprice1 +=$totprice; $tot_weight_2 +=$new_qty; $Query_job_move_product = mysql_query("SELECT * from shop_product_image where product_id='$menuid_d_s' order by product_id asc "); $row_job_move_product_id = mysql_fetch_array($Query_job_move_product); ?>
0) { ?>
   Product Totala
    x 0) { ?> 0) { ?>(0) { ?>+ Free  
)
    x
   Cart Total
   Weight
   Shipping&Packing Charges .00 0) { $courier_fees_country=$row_job_move_courier_country['amount']; $courier_fees_country_extra=$row_job_move_courier_country['additional_amount']; } else { $Query_job_move_courier_country= mysql_query("SELECT * from tbl_courier_charges_country where state='Others' "); $row_job_move_courier_country= mysql_fetch_array($Query_job_move_courier_country); $courier_fees_country=$row_job_move_courier_country['amount']; $courier_fees_country_extra=$row_job_move_courier_country['additional_amount']; } if($tot_weight_2_int<=500) { $courier_fees_country_1=$courier_fees_country; } else { $tot_weight_2_int_1=($tot_weight_2_int-500); $tot_weight_2_int_1_2=($tot_weight_2_int_1/250); $new_kilo_5_int = explode('.',$tot_weight_2_int_1_2); $new_kilo_6_int=$new_kilo_5_int[0]; $new_kilo_6_int_7=($new_kilo_6_int+1); $new_kilo_6_int_7_8=($courier_fees_country_extra*$new_kilo_6_int_7); $courier_fees_country_1=($courier_fees_country+$new_kilo_6_int_7_8); } ?>
   Order Total ( Inclusive of GST )
0 && $weight <=1){ $courier = $set_c['amount']; }elseif($weight > 1 && $weight <=2){ $courier = $set_c['amount'] *2; }elseif($weight > 2){ $extra = $weight - 2; $courier = ($set_c['amount'] * 2) + (ceil($extra) * $set_c['3_rd_kg']); } return $courier; } ?>