Assuming your values are 0 or 1 for product_ships_UPS_only where 1 means yes only UPS, you could use the code below in RED in the file:
/includes/modules/shipping/usps.php
global $template, $current_page_base;
// CUSTOMIZED CONDITIONS GO HERE
// Optionally add additional code here to change $this->enabled to false based on whatever custom rules you require.
// -----
[B]// bof: check cart for UPS only products
$ups_only = $_SESSION['cart']->in_cart_check('product_ships_UPS_only','1');
if ($ups_only) {
$this->enabled = false;
}
// eof: check cart for UPS only products
[/B] // -----
// eof: optional additional code
}
$this->notify('NOTIFY_SHIPPING_USPS_UPDATE_STATUS');
You can adapt something like that for UPS, but I have not looked at it yet ...
Linda McGrath
If you have to think ... you haven't been zenned ...
**Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!**
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today!]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!