multiple vendor shipping-how implement indvidual shipping,
geckorello <[email protected]>
| Newsgroups | gmane.comp.web.oscommerce.installation |
|---|---|
| Message-ID | <4e48eabe9924b3bf0661c3940503904b@osCommerce-Forums> |
This message was sent from: Installation and Configuration
http://forums.oscommerce.com/viewtopic.php?p=227470#227470
----------------------------------------------------------------
hi readers, if have the following probelm:
i have just installed MULTIPLE VENDOR SHIPPING and I want to USE "individual shipping costs" and "table shipping costs" and "flat rate" as shipping methods. how can I implement these shipping methods in catalog/includes/modules/shipping/mltship.php.
its in the code here
I don´t know what to insert after "case flat:"
[code]if($shipping_weight > 0)
{
//Setup the varibles needed
$mlt_num_boxes = ceil($shipping_weight/$row['max_box_weight']);
$shipping_weight /= $mlt_num_boxes;
$shipping_weight += $row['tare_weight'];
switch ($row['module_name'])
{
case "ups":
$rate = new ups;
$mltQuote = $rate->quote('GNDRES');
//Any other module specific processing / charges should be done here
break;
case "indvship":
$rate = new indvship;
//$mltQuote = $rate->quote('GNDRES');
//Any other module specific processing / charges should be done here
break;
case "flat":
$rate = new flat;
/*$rate->quote[0]['methods'][1]['title'] = FREE_SHIPPING_TITLE;
$rate->quote[0]['methods'][1]['cost'] = '80';
echo $rate->quote[0]['methods'][1]['cost'];
/* } else {*/
// $rate->quote=quote($method, $module);
//$this->quote = $rate->getPrice();
/*$rate->upsProduct($prod); // See upsProduct() function for codes
$country_name = tep_get_countries(STORE_COUNTRY, '1');
$rate->origin(STORE_ORIGIN_ZIP, $country_name['countries_iso_code_2']); // Use ISO country codes!
$country_name = tep_get_countries($address_values['country_id'], '1');
$country_post = str_replace(' ', '', $address_values['postcode']);
$rate->dest($country_post, $country_name['countries_iso_code_2']); // Use ISO country codes!
$rate->rate(MODULE_SHIPPING_UPS_PICKUP); // See the rate() function for codes
$rate->container(MODULE_SHIPPING_UPS_PACKAGE); // See the container() function for codes*/
//$rate->quote="20";
//echo " test ".$rate->quote. " test";
break;
case "table":
$rate = new table;
//$mltQuote = $rate->quote('GNDRES');
//Any other module specific processing / charges should be done here
break;
case "zones":
$rate = new zones;
//$mltQuote = $rate->quote('GNDRES');
//Any other module specific processing / charges should be done here
break;
case "usps":
$rate = new usps;
$mltQuote = $rate->quote('Priority');
//Any other module specific processing / charges should be done here
break;
}
//Post quote processing
//Add global handling charge... set the global handling to 0 if you don't use it
$shipping_mltship_cost += (SHIPPING_HANDLING + $mltQuote['methods'][0]['cost']) * $mlt_num_boxes;
if($row['handling_per_box'] == 1)
$shipping_mltship_cost += $row['handling_charge'] * $mlt_num_boxes;
else
$shipping_mltship_cost += $row['handling_charge'];;
}
}[/code]
does anybody know this, thanks in advance, georg