Jump to content


  • Content count

  • Joined

  • Last visited

1 Follower

Profile Information

  1. lorax

    State Based Region Shipping Rates

    I've got a selection of products that are rather heavy. Some as much as several hundred pounds. Some as light as only a few pounds. I've set up for shipping methods gnd, next day, 2nd day, and freight. I'm using 3 regions for each. Right now, when I set the store's shipping limit to 120, some funny things happen to products which weigh over the limit. Their weights get divided and I end up with a shipping weight that is some fraction of the original. So - I bump this up. If I set the store's limit to 10000 and then set the limits on the individual methods (ie. gnd is 120:0.40) then it works for a single item over the 120 limit. But if I have 3 items with a total combined weight over 120 and individual rates of less than 120 then all methods are valid and shipping rates for them should be displayed - but they aren't. If I leave the store's limit at 10000 AND set the limits for each method to 10000, then I get valid shipping rates for all of the methods in both cases (one item over 120 and several items combined). BUT I only want the freight quote to be displayed if any quantity of a single item that weighs over 120# is selected. What I'd like to do is to modify the code such that it will identify any units over the limit set in the Configuration > Shipping/Packaging > Enter the Maximum Package Weight field and set all but the Freight option to "unavailable" or some such text which I believe can be set using MODULE_GROUND_SHIPPING_REGIONS_UNDEFINED_RATE Any combined weights over this limit should offer all 4 shipping options as long as no single unit is over the store's limit. Where in the code would be the best place to implement this? Within the individual method files (gnd, etc...)? TIA - and thanks for creating this contrib!
  2. Ah ha. Locate at about line 205 in catalog/index.php and change to
  3. Contrib: http://www.oscommerce.com/community/contributions,2541 Installed and working for the 1st page of any product listing within the catalog. As soon as I click to view the next page, the sorting falls to pieces. Click << previous and the 1st page no longer sorts correctly.
  4. lorax

    Sort shipping modules?

    Thanks Oppen, Bingo! I simply renamed the shipping modules to fit the sort order I wanted and it worked perfectly. Oh... and I had to modify the sections where the code called for the filenames as well!
  5. lorax

    Sort shipping modules?

    I've modified the State Based Rates contribution so that I have 4 copies of it. One for each different shipping method I need (ground, 2 day, etc..). They each installed fine and work fine but they don't display on checkout_shipping in the order I want them to. I tried adding sort_order values to the configuration table since I don't see a way to do it using the shipping module controls in Admin. I was going to do a sort on the value that the quotes function returns but it's a multi-dimensional array and I can't find a way to tell sort what field I want to sort on. I'm beginning to think the only way to do this is to parse through the array and build a new one before outputting it to screen. Then I can sort on any field I wish. Does this seem like a reasonable way to approach this or is there an easier way?
  6. lorax

    Modified Shipping Zones Mod

    I ended up using the State Based Rates contribution and modified it to suit my needs. Works pretty slick.
  7. lorax

    Modified Shipping Zones Mod

    Oh crumbs. I'm confusing myself. The Zones table is already made up of states!
  8. Hola, I've been playing around with several different shipping modules attempting to cobb something together to accomplish the following: 4 (or more) zones (groups of US States) Each zone has 4 (or more) methods of shipping (ground, 2nd day, next day, & freight) Each method can be turned on or off for any zone and rates may be substituted with a message (ex: freight to Hawaii isn't a standard rate from the east coast!) Each method is expressed as a price per pound rate Each method has a minimum shipping charge Shipping cost is determined in a simply formula of weight X price per pound I'm thinking I should take a copy of the basic Zone Shipping module and modify it to suit my needs. And I'm thinking that I need to make a copy of the zones table and convert the countries into states. Basically mimic the Zones Shipping Module but at the State level instead of the Country level and then add in extras. I'm a bit worried that I might be headed for trouble since I'm not that comfortable with how the shipping modules work (especially the install and uninstall code). Some feedback and or pointers would be most appreciated.
  9. I've taken the Llyod Swadling's contrib and modified it for the US. I'm not using the zipcodes but rather using states (in fact I dropped the toll_zones table alltogether). I've modified the toll_rates table to include additional columns - 1 for each shipping method. So for any given state I have a rate for UPS ground, Next Day, 2nd Day and Freight. I can pull the data into the shipping module fine. The problem I'm having is how to pass it to checkout_shipping.php so that each of the shipping methods is presented. My version of the quote function in tollzipzones.php: function quote($method = '') { global $order, $shipping_weight, $shipping_num_boxes; // First get the dest state and check the db for our dest state's code $state = $order->delivery['state']; if ( $state == '' ){ // Something is wrong, we didn't find any code $this->quotes['error'] = MODULE_SHIPPING_TOLLZIPZONES_NO_ZIPCODE_FOUND; return $this->quotes; } $sql = "SELECT zone_code FROM zones WHERE '$state' = zone_name"; $qResult = tep_db_query($sql); // run the query $rec = tep_db_fetch_array($qResult); // get the first row of the result $zone_code = $rec['zone_code']; if ( $zone_code == '' ){ // Something is wrong, we didn't find any zone $this->quotes['error'] = MODULE_SHIPPING_TOLLZIPZONES_NO_ZONE_FOUND; return $this->quotes; } $sql = "SELECT ground,one_day FROM toll_rates WHERE t_zone_id = '$zone_code'"; $qResult = tep_db_query($sql); while ($rec = tep_db_fetch_array($qResult)) {$retArr[] = $rec;} foreach($retArr as $aquote){ $ground = $aquote['ground']; $one_day = $aquote['one_day']; } // set a minimum cost for the shipping if ($ground < 9.95) $gnd_cost = 9.95; else $gnd_cost = $ground * $shipping_weight; if ($one_day < 24.99) $one_cost = 24.99; else $one_cost = $one_day * $shipping_weight; /***$cost = array('ground'=>$gnd_cost, 'one_day'=>$one_cost ); for ($i=0;$i<count($cost);$i++){ $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_TOLLZIPZONES_TEXT_TITLE, 'methods' => array(array('id' => $this_code, 'title' => MODULE_SHIPPING_TOLLZIPZONES_TEXT_DESCRIPTION, 'cost' => ##($cost['one_day'])+ MODULE_SHIPPING_TOLLZIPZONES_HANDLING))); } if ($error == true) $this->quotes['error'] = MODULE_SHIPPING_TOLLZIPZONES_INVALID_ZONE; return $this->quotes;***/ } The section between the /*** and ***/ is where I'm having difficulty. I was under the impression (mistakenly) that I would be able to loop over this section and I would be able to display the multiple shipping options on checkout_shipping.php. I left my test code (marked with a ##) in place. I can switch from $cost['one_day'] to $cost['ground'] and I get the correct output for that shipping method. SO... if you can offer some info on how to achieve multiple shipping options I'd sure appreciate it!
  10. I've got a customer who has a LinkPoint account. I saw there are two contributions for a LinkPoint gateway plugin. Could someone tell me a bit about the pros/cons of using one or the other or does it really matter? TIA.
  11. Otto, It is possible to do nearly anything with osC (aside from making your morning coffee). Since you're new to osC, you should count on it taking some time to get up to speed with how the cart is built and where everything is before you are able to edit it. Unless you're very comfortable with PHP and wrapping your head around someone else's code. The Purchase Without An Account contribution simply offers the visitor yet another method to check out. It does not disable the login or account sign up procedures. Think of it as an end run around them. HTH
  12. FWIW - I think the concept of a single thread for a contribution is too limiting. I'd like to see at least 3 threads per contribution - seperated from the other contribs by it's own forum. The three threads would be 1) Announcements: where the contributor only can provide updates, announcements, etc.. 2) Installation & Configuration: where anyone having trouble with getting the contrib working can post 3) Tips & FAQs: where members can post what they've learned after installing the contrib so that others can find it more readily. I realize that the thought of putting up a forum for each contribution may be daunting but I think it would be very helpful. As it stands now, all of the contributions are tossed together into one pile and that is very daunting to newbies. Especially those who are less than skilled with using the search.
  13. >> I'm not positive but I think tails2k means the main border around the infobox. DOH! I must have been a bit groggy - I can see that now. Re: style - you could also define a seperate style for this particular box - a copy of the original. Then you could modify it and not affect the other boxes.
  14. That's not a border - it's the way the browser displays what is supposed to be an image - which doesn't exist. I think you can tell osC not to require images. Check the admin interface for it. As for the background color. I believe it is set by a style. Open the file up and look for the code that outputs those products. You should find a style applied to the table, tr or td elements. If not, it might be a default - check the style sheet. HTH