RE: Local, City, County Sales Tax and Taxes
ocularmagic <[email protected]>
| Newsgroups | gmane.comp.web.oscommerce.features |
|---|---|
| Message-ID | <9fb341096a82686bece7edf8608b1390@osCommerce-Forums> |
This message was sent from: Features
http://forums.oscommerce.com/viewtopic.php?p=162553#162553
----------------------------------------------------------------
If that is the case, give the following code a try. No guarantees that it will work, but it will be a starting point at least.
[code]
global $customer_id;
$customer_city_query = tep_db_query("select entry_city from " . TABLE_ADDRESS_BOOK . " where customers_id = '" . $customer_id . "'");
$customer_city = tep_db_fetch_array($customer_city_query);
// Must take $customer_city['entry_city'] and make it either all caps or all
// lower case because some customers capitalize and some don't.
// I don't know the function off the top of my head.
if ($customer_city['entry_city'] == 'denver') {
return 7.9; // Not sure what the usual return is, but think it should be
// a value similar to this.
}
[/code]
You could place this right after the other variable declarations at the thop of the function so it always checks this first without running through the whole thing for nothing. Hope that helps.