Jump to content

adw49

Members
  • Content count

    26
  • Joined

  • Last visited

Profile Information

  • Real Name
    Andy
  • Gender
    Male
  • Location
    Sarasota, FL

Recent Profile Visitors

3,581 profile views
  1. adw49

    UPS shipping module for oscommerce 2.3

    So what did you install? Which contribution?
  2. adw49

    Country-State Selector

    Thanks Steve, Unfortunately my knowledge of PHP is very limited. I have managed do a work around, by going to the database record via phpMyAdmin, and changing the feild content there. This should only be necessary very occasionally if someone tries to register as Tax Exempt without submitting their FL Tax Certificate, then we just change the zone_id # to the county #. Tested it, it works. But many thanks anyway.
  3. adw49

    Country-State Selector

    Thanks for the info. I have managed to get the state abbrev. to appear on the invoice, order etc. Perhaps you may be able to help with a different problem. If I try and change anything on a customers account, for example, they chose the wrong State/County, I can change it but the record is not saved when I hit the update button in admin. I have tried everything I can think of, but nothing makes any difference. Thanks again.
  4. adw49

    Country-State Selector

    Steve, I have just installed your cont. and it works great, except for the fact that because I am in Florida, and require multiple tax rates, I created zones and tax zones for each county, for example Florida-Manatee Count (FL), etc., but instead of just the zone code appearing on the customer's billing and shipping address when I look at orders placed, I get the whole zone name with the zip code following. I have tried looking for the code in all the pages, changed some to your suggestion of 18 June, 2011, but nothing changed. I really would appreciate any help you can give. I need the zone name in the drop down to apply the correct sales tax, but only the zone code to appear on any output, such as invoice, delivery note etc. Thanks in advance.
  5. adw49

    Register Globals Support

    Hope someone can help with this error which appears the first time the index page loads: Warning: session_write_close() [function.session-write-close]: Your script possibly relies on a session side-effect which existed until PHP 4.2.3. Please be advised that the session extension does not consider global variables as a source of data, unless register_globals is enabled. You can disable this functionality and this warning by setting session.bug_compat_42 or session.bug_compat_warn to off, respectively. in /home/serescom/public_html/includes/functions/sessions.php on line 136 I've looked at line 136 but can't find anything relating to the error message. Thanks all.
  6. adw49

    Zone Shipping by State, Ver. 1.0

    Skittles & Sean Thought I would give you an update. I corrected the '}' problem and uploaded the files again. Worked this time without any errors - thanks. Only one thing, I have already on the 'select shipping' method a 'UPS Ground' which uses the State name to determine costs by zones. If I activate the interstate shipping method, which I wanted to use for UPS 2nd day air shipping, it prevents the 'ground' option from appearing. Could I change the interstate to accept state names, instead of the abbreviation and leave the order.php file as is, or would that totally screw things up? Or is that not the reason I'm not seeing the first option? ADW
  7. adw49

    New UPS XML Shipping Module available

    Sorry it's taken me so long to reply, but after I sent my earlier message, my system/server crashed and after trying several restores, had to get the hosting company to restore from their server backup and I haven't had a chance to look at it yet. Will let you know what I find. Thanks
  8. adw49

    New UPS XML Shipping Module available

    Thanks, Uploaded the correct file, installed without any visible problems, but now after entering all my UPS details, and go to checkout with one item in shopping cart, all I get is FREE SHIPPING OVER $50. The itme is less than $10. My original shipping method doesn't even appear. HELP!!!!!
  9. adw49

    Zone Shipping by State, Ver. 1.0

    Sean, Here is my interstate.php file - Is it correct? Sorry I don't know how to copy the line numbers. Andy. <?php /* $Id: Interstate.php Contributed by Anita L. Cross (aka skittles) (http://www.callofthewildphoto.com) Zone Shipping: By State Within A Country Developed For USA. Can be adapted to other countries. Based on Zones.php, distributed with osCommerce MS2.2 (051113) For Use with: osCommerce, Open Source E-Commerce Solutions http://www.oscommerce.com Released under the GNU General Public License */ class interstate { var $code, $title, $description, $enabled, $num_zones; // class constructor function interstate() { $this->code = 'interstate'; $this->title = INTERSTATE_TEXT_TITLE; $this->description = INTERSTATE_TEXT_DESCRIPTION; $this->sort_order = INTERSTATE_SORT_ORDER; $this->icon = ''; $this->tax_class = INTERSTATE_TAX_CLASS; $this->enabled = ((INTERSTATE_STATUS == 'True') ? true : false); // CUSTOMIZE THIS SETTING FOR THE NUMBER OF ZONES NEEDED $this->num_zones = 6; } // class methods function quote($method = '') { global $order, $shipping_weight, $shipping_num_boxes; // if delivery is to other country, skip module in cart if ($order->delivery['country']['iso_code_2'] != 'US') return; $dest_state = $order->delivery['state']; $dest_zone = 0; $error = false; for ($i=1; $i<=$this->num_zones; $i++) { $state_table = constant('INTERSTATE_STATES_' . $i); $state_zones = split("[ ,]", $state_table); if (in_array($dest_state, $state_zones)) { $dest_zone = $i; break; } } if ($dest_zone == 0) { $error = true; } else { $shipping = -1; $interstate_cost = constant('INTERSTATE_COST_' . $dest_zone); $interstate_table = split("[:,]" , $interstate_cost); $size = sizeof($interstate_table); for ($i=0; $i<$size; $i+=2) { if ($shipping_weight <= $interstate_table[$i]) { $shipping = $interstate_table[$i+1]; $shipping_method = INTERSTATE_TEXT_WAY . ' ' . $dest_state . ' : ' . $shipping_weight . ' ' . INTERSTATE_TEXT_UNITS; break; } } if ($shipping == -1) { $shipping_cost = 0; $shipping_method = INTERSTATE_UNDEFINED_RATE; } else { $shipping_cost = ($shipping * $shipping_num_boxes) + constant('INTERSTATE_HANDLING_' . $dest_zone); } } $this->quotes = array('id' => $this->code, 'module' => INTERSTATE_TEXT_SECTION_TITLE, 'methods' => array(array('id' => $this->code, 'title' => $shipping_method, 'cost' => $shipping_cost))); if ($this->tax_class > 0) { $this->quotes['tax'] = tep_get_tax_rate($this->tax_class, $order->delivery['country']['id'], $order->delivery['zone_id']); } if (tep_not_null($this->icon)) $this->quotes['icon'] = tep_image($this->icon, $this->title); if ($error == true) $this->quotes['error'] = INTERSTATE_INVALID_ZONE; return $this->quotes; } function check() { if (!isset($this->_check)) { $check_query = tep_db_query("select configuration_value from " . TABLE_CONFIGURATION . " where configuration_key = 'INTERSTATE_STATUS'"); $this->_check = tep_db_num_rows($check_query); } return $this->_check; } function install() { tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, set_function, date_added) VALUES ( 'Enable Zones USA Method', 'INTERSTATE_STATUS', 'True', 'Offer USA specific zone rates by state?', '6', '0', 'tep_cfg_select_option(array(\'True\', \'False\'), ', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, use_function, set_function, date_added) VALUES ( 'Tax Class', 'INTERSTATE_TAX_CLASS', '0', 'Use the following tax class on the shipping fee.', '6', '0', 'tep_get_tax_class_title', 'tep_cfg_pull_down_tax_classes(', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ( 'Sort Order', 'INTERSTATE_SORT_ORDER', '0', 'Sort order of display.', '6', '0', now())"); for ($i = 1; $i <= $this->num_zones; $i++) { $default_states = ''; $default_rates = ''; if ($i == 1) { $default_states = 'FL'; $default_rates = '1:11.30,2:11.50,3:11.90,4:12.40,5:12.80'; } if ($i == 2) { $default_states = 'NC, SC, GA, AL, TN'; $default_rates = '1:11.80,2:12.00,3:12.60,4:13.80,5:15.20'; } if ($i == 3) { $default_states = 'NJ, DC, MD, VA, WV, MS, KY, OH, IN, MO, LA, AR'; $default_rates = '1:12.60,2:13.70,3:15.40,4:17.30,5:19.50'; } if ($i == 4) { $default_states = 'CT, NY, PA, DE, MI, IA, NE, WI, IL, KS, OK'; $default_rates = '1:14.70,2:16.80,3:19.20,4:21.80,5:24.50'; } if ($i == 5) { $default_states = 'MA, RI, NH, VT, ME, MN, SD, NE, TX, CO, NM'; $default_rates = '1:15.30,2:18.10,3:20.80,4:23.60,5:26.40'; } if ($i == 6) { $default_states = 'ND, MT, WY, ID, UT, AZ, NV, CA, WA'; $default_rates = '1:16.10,2:18.40,3:21.20,4:24.20,5:27.40'; tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ('Zone " . $i ." States', 'INTERSTATE_STATES_" . $i ."', '" . $default_states . "', 'Comma separated list of two character ISO State codes that are part of Zone " . $i . ".', '6', '0', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ('Zone " . $i ." Shipping Table', 'INTERSTATE_COST_" . $i ."', '" . $default_rates . "', 'Shipping rates to Zone " . $i . " destinations based on a group of maximum order weights. Example: 3:8.50,7:10.50,... Weights less than or equal to 3 would cost 8.50 for Zone " . $i . " destinations.', '6', '0', now())"); tep_db_query("insert into " . TABLE_CONFIGURATION . " (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, date_added) VALUES ('Zone " . $i ." Handling Fee', 'INTERSTATE_HANDLING_" . $i."', '5.00', 'Handling Fee for this shipping zone', '6', '0', now())"); } } function remove() { tep_db_query("delete from " . TABLE_CONFIGURATION . " where configuration_key in ('" . implode("', '", $this->keys()) . "')"); } function keys() { $keys = array('INTERSTATE_STATUS', 'INTERSTATE_TAX_CLASS', 'INTERSTATE_SORT_ORDER'); for ($i=1; $i<=$this->num_zones; $i++) { $keys[] = 'INTERSTATE_STATES_' . $i; $keys[] = 'INTERSTATE_COST_' . $i; $keys[] = 'INTERSTATE_HANDLING_' . $i; } return $keys; } } } ?>
  10. adw49

    Zone Shipping by State, Ver. 1.0

    Sean, I uploaded the original modules.php and still got the error. Here is line 152: $key_value_query = tep_db_query("select configuration_title, configuration_value, configuration_description, use_function, set_function from " . TABLE_CONFIGURATION . " where configuration_key = '" . $module_keys[$j] . "'"); The error appears when I try to install via admin. Andy.
  11. adw49

    Zone Shipping by State, Ver. 1.0

    Skittles, I have installed the module as per instructions, but as soon as I select it to install I get the following error: Fatal error: Call to undefined function: keys() in /home/serescom/public_html/admin/modules.php on line 152 Any idea what I have done wrong, if anything. The only changes I made were to the number of zones, increased to 6, and made text changes. Thanks, Andy.
  12. adw49

    New UPS XML Shipping Module available

    I posted this in the Shipping modules section before I found the link to this. Can anyone help with the following error? I uploaded the files as per the instructions, making all necessary changes, but when I select the "Edit" button to enter my details, I get this: Fatal error: Call to undefined function: tep_cfg_select_multioption() in /home/serescom/public_html/admin/modules.php(216) : eval()'d code on line 1 Any ideas? Thanks. A.
  13. adw49

    State Based Region Shipping Rates

    State Based Shipping "copied the 2 files and changed names to express_regions, then changed content so any instance of: MODULE_SHIPPING_REGIONS becomes MODULE_SHIPPING_EXPRESS_REGIONS and regions becomes express_regions" It displays correctly on checkout_shipping.php but when you choose the Express one and hit continue it takes you to checkout_shipping.php again. It gets stuck on that page instead of going to the next one (checkout_payment.php) Did anyone ever get this resolved? ADW
×