<?php 
session_start();
ob_start();
include('uos.php');

$_SESSION['state']=$_POST['state']; 
 $_SESSION['service']=$service = $_POST['service'];


 $_SESSION['weight2']=$weight = $_POST['weight'];

  $_SESSION['zipcode']=$dest_zip = $_POST['zipcode'];

  
  

$ups = new ups; 
$ups->set_src_zip('92707'); 
$ups->set_dst_zip($dest_zip); 
$ups->set_weight($weight); 
$ups->set_delivery_code($service); 
$ups_cost = $ups->get_cost(); 



   $_SESSION['ship']=$ups_cost; 

 /*if($_POST['state']=='CA') {
  $_SESSION['tax']=8.25;
   } else {
     $_SESSION['tax']=number_format(0.00,2);
	  } */
	 
	
 
header("Location:checkout.php");

?>