meta as $key=>$val) {
if (!empty($val)) {
echo " " . __($key, 'yak') . ":" . __($val, 'yak') . " ";
}
}
?>
|
$total_price, 'state'=>$billing_state, 'country'=>$billing_country));
$add_to_price =& $GLOBALS['yak-add-to-price'];
foreach ($add_to_price as $add) {
$total_price += $add;
}
$grand_total = $total_price;
// calculate shipping
if (yak_get_option(INCLUDE_SHIPPING_COSTS, 'no') == 'yes') {
global $shipping_costs;
$shipping_opt = $_POST[SELECTED_SHIPPING_OPTION];
if (empty($shipping_opt)) {
$shipping_options = yak_get_shipping_options();
$shipping_opt = reset($shipping_options);
}
$cty = str_replace(' ', '_', $_POST[SHIPPING_COUNTRY]);
$act_shipping_cost = yak_calc_shipping($total_weight, $totals->quantity, $cty, $shipping_opt);
$grand_total += $act_shipping_cost;
if ($promo != null) {
$shipping_discount = yak_calc_shipping_discount($act_shipping_cost, $promo, $model['items']);
if ($shipping_discount > 0) {
$grand_total -= $shipping_discount;
$total_discount = $shipping_discount;
}
}
?>