You would add the code to:
Code:
$methods = array();
$size = sizeof($uspsQuote);
for ($i=0; $i<$size; $i++) {
list($type, $cost) = each($uspsQuote[$i]);
// BOF: UPS USPS
$title = ((isset($this->types[$type])) ? $this->types[$type] : $type);
if(in_array('Display transit time', explode(', ', MODULE_SHIPPING_USPS_OPTIONS))) $title .= $transittime[$type];
/*
$methods[] = array('id' => $type,
'title' => ((isset($this->types[$type])) ? $this->types[$type] : $type),
'cost' => ($cost + MODULE_SHIPPING_USPS_HANDLING) * $shipping_num_boxes);
*/
global $cart;
// $chk_cats = $_SESSION['cart']->in_cart_check('master_categories_id','11') + $_SESSION['cart']->in_cart_check('master_categories_id','12');
echo 'shipping ' . $type . ' chk_cats: ' . $chk_cats . '<br>';
if ($type == 'Express Mail International (EMS) Flat-Rate Envelope' && $chk_cats > 0) {
// skip shipping
} else {
$methods[] = array('id' => $type,
'title' => $title,
'cost' => ($cost + MODULE_SHIPPING_USPS_HANDLING) * $shipping_num_boxes);
}
}
The commented echo is if you need to see the name of the shipping type for testing other settings ... just uncomment and it will display on the shipping ... note: it will look pretty ugly but it is helpful ...