Jump to content

carpesitus

Members
  • Content count

    3
  • Joined

  • Last visited

1 Follower

Profile Information

  • Real Name
    John
  1. carpesitus

    Need PHP help, please

    I'm trying to add an additional condition to a per item shipping module. It is processing the zone properly but I can't get it to calculate the shipping correctly. It returns a $0.00 shipping total. Here is the code: if ($dest_zone == 0) { $groups_cost = constant('MODULE_SHIPPING_PIPC_COST_DEFAULT'); $handle_cost = constant('MODULE_SHIPPING_PIPC_HANDLING_DEFAULT'); } elseif ($dest_zone == 1 && $total_count > 2) { $shipping_cost = $groups_cost + $groups_cost; } else { $groups_cost = constant('MODULE_SHIPPING_PIPC_COST_' . $dest_zone); $handle_cost = constant('MODULE_SHIPPING_PIPC_HANDLING_' . $dest_zone); } $shipping_method = MODULE_SHIPPING_PIPC_TEXT_WAY . ' ' . $dest_country . ' : ' . $shipping_weight . ' ' . MODULE_SHIPPING_PIPC_TEXT_UNITS; $shipping_cost = $groups_cost * $total_count + $handle_cost; $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_PIPC_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => $shipping_method, 'cost' => $shipping_cost)));
  2. carpesitus

    Per Item Per Country with a max shipping fee

    I could use some help with the php asap. What I need to do is add a condition for the United States if the item count is >2 the shipping_cost is $14.00 if ($dest_zone == 0) { $groups_cost = constant('MODULE_SHIPPING_PIPC_COST_DEFAULT'); $handle_cost = constant('MODULE_SHIPPING_PIPC_HANDLING_DEFAULT'); } else { $groups_cost = constant('MODULE_SHIPPING_PIPC_COST_' . $dest_zone); $handle_cost = constant('MODULE_SHIPPING_PIPC_HANDLING_' . $dest_zone); } $shipping_method = MODULE_SHIPPING_PIPC_TEXT_WAY . ' ' . $dest_country . ' : ' . $shipping_weight . ' ' . MODULE_SHIPPING_PIPC_TEXT_UNITS; $shipping_cost = $groups_cost * $total_count + $handle_cost; $this->quotes = array('id' => $this->code, 'module' => MODULE_SHIPPING_PIPC_TEXT_TITLE, 'methods' => array(array('id' => $this->code, 'title' => $shipping_method, 'cost' => $shipping_cost))); Thanks
  3. Hello, I am an admin and the site owner would like a flate rate per item per country. That part is set up and working, now they would like to put a cap on the domestic shipping fee. This can be either a maximum $$ amount for domestic shipping or only charge shipping for the first 2 items. Currently I am using Per Country Per Item v1.1 for the shipping module. http://addons.oscommerce.com/info/4934/v,22 Does anyone have a suggestion for setting up a maximum shipping amount on one group (domestic)?
×