Just thinking. According to Ajeh's post adding coding to 1 area (the UPS module) would change this from Residental to Commercial if someone filled out the Company Field. With this same logic wouldn't it be just a tad more work to make a checkbox (business/residence) on the shipping form as the flag?
Now I already stated I do not know coding, but something like this on the _upsRescom page. Coders please do not wish me harm for writing what I do not know :
Code:
function _upsRescom($foo) {
global $order;
/*
switch ($foo) {
case 'RES': // Residential Address
$this->_upsResComCode = '1';
break;
case 'COM': // Commercial Address
$this->_upsResComCode = '0';
break;
}
*/
//echo 'UPS company: ' . ($order->delivery['Business'] == '' ? 'No check' : 'Check') . ' len:' . strlen($order->delivery['Business']) . '<br>';
if ($order->delivery['Business'] == '') {
$this->_upsResComCode = '1';
} else {
$this->_upsResComCode = '0';
}
//echo 'UPS residence: ' . ($order->delivery['Residence'] == '' ? 'No check' : 'Check') . ' len:' . strlen($order->delivery['Residence']) . '<br>';
if ($order->delivery['Residence'] == '') {
$this->_upsResComCode = '1';
} else {
$this->_upsResComCode = '0';
}
}
Then on the shipping address php page, for put coding for a business/residence checkbox. This checkbox coding would also obviously be plugged into the coding above to work together. I would only think this would be 2 file modifications.
Bookmarks