Jump to content



Photo
* * * * * 1 votes

Shipping in cart


  • Please log in to reply
36 replies to this topic

#21   MaceBiz

MaceBiz

    Skills Trade in Profile

  • Members
  • 6 posts
  • Real Name:Aaron Mullins
  • Gender:Male
  • Location:England, UK

Posted 15 March 2013 - 14:28

Thanks, yes that did help, I think I have it all working now.

Does anybody know how to change the dropdown menu to show a specific country as the default?

I have managed to achieve this for the other dropdown menus on my site by editing the includes/functions/html_output.php
From this:

function tep_get_country_list($name, $selected = '', $parameters = '') {
$countries_array = array(array('id' => '', 'text' => PULL_DOWN_DEFAULT));

To this:

function tep_get_country_list($name, $selected = '222', $parameters = '') {
$countries_array = array(array('id' => '222', 'text' => 'United Kingdom'));

But it didn't affect this one?

#22   sembrouille

sembrouille
  • Members
  • 83 posts
  • Real Name:brouillard
  • Gender:Male

Posted 16 April 2013 - 08:20

Your shop is not configured.

You must set the country in :

admin -> shop -> country

#23   14steve14

14steve14
  • Members
  • 3,505 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Dorset UK

Posted 24 April 2013 - 08:42

I have this installed and love it.

Is there any way to get the shipping costs to show in the dropdown, rather than when the page refreshes after selecting a shipping method.
REMEMBER BACKUP, BACKUP AND BACKUP

Don't take life too seriously. no one gets out alive anyway

#24   Bob Terveuren

Bob Terveuren
  • Members
  • 320 posts
  • Real Name:Bob Terveuren
  • Gender:Male

Posted 10 May 2013 - 08:40

I have this installed and love it.

Is there any way to get the shipping costs to show in the dropdown, rather than when the page refreshes after selecting a shipping method.


Hi Steve

I'm not sure if this is what you mean but.....

Around line 109 find //------------------- fin affiche fdp ---------------------------------------------------- , count up two closing curly wurlies and add the line shown - that should get you the dropdown displaying 'Royal Mail (£12.87)' instead of 'Royal Mail'

//altering dropdown text
$quotes_array[$i]['text'].= ' ('.$currencies->format( tep_add_tax((float)$calcul_fdp_scart, $tax_fdp)).')';
//end
}
}
//------------------- fin affiche fdp ----------------------------------------------------

p.s. first I've seen this one and it's a much nicer add-on than the older ship in cart contribution - well done MrFoggy

Edited by Bob Terveuren, 10 May 2013 - 08:42.


#25   treefrog69

treefrog69
  • Members
  • 1 posts
  • Real Name:Chris Hartung

Posted 24 June 2013 - 01:07

Can someone tell me if this item supports zip/postal code lookup for US to US shipping? I am using the USPS and UPS add ons for shipping, my site is 2.3.3

#26   14steve14

14steve14
  • Members
  • 3,505 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Dorset UK

Posted 24 June 2013 - 07:59

Hi Steve

I'm not sure if this is what you mean but.....

Around line 109 find //------------------- fin affiche fdp ---------------------------------------------------- , count up two closing curly wurlies and add the line shown - that should get you the dropdown displaying 'Royal Mail (£12.87)' instead of 'Royal Mail'

//altering dropdown text
$quotes_array[$i]['text'].= ' ('.$currencies->format( tep_add_tax((float)$calcul_fdp_scart, $tax_fdp)).')';
//end
}
}
//------------------- fin affiche fdp ----------------------------------------------------

p.s. first I've seen this one and it's a much nicer add-on than the older ship in cart contribution - well done MrFoggy


@Bob Terveuren

I tried the above, but it only put in the costs of the chosen service, not the costs of all the available services. I will look into this more, and compare with an older similar addon and see if I can get it to show the prices of each individual service next to where it lists the services in the dropdown box. At the moment you have to click on the service type to get the price guote, and I think it would be better if the price showed next to the service.
REMEMBER BACKUP, BACKUP AND BACKUP

Don't take life too seriously. no one gets out alive anyway

#27   Bob Terveuren

Bob Terveuren
  • Members
  • 320 posts
  • Real Name:Bob Terveuren
  • Gender:Male

Posted 27 June 2013 - 19:09

@14steve14
Hi Steve - it works for the basic stuff like table rates, flat rate etc etc but I think it may be failing on the RM stuff if it's looking for zones??

I haven't time to look at it but if you look at the quotes function in the RM module and see what it requires before it will spit out a quote then the answer is in that bit I reckon

#28   simonhornby

simonhornby

    simonhornby

  • Members
  • 21 posts
  • Real Name:Simon Hornby
  • Gender:Male
  • Location:Chester, England

Posted 14 July 2013 - 20:26

Hi, Great contribution, thanks!!

Please will you let me know how I can include a free shipping module (not necessarily ot_free_shipping) in the drop down list.

We offer fee shipping and expedited shipping (at a cost) to our customers. So it is important they can see all shipping options which are available. Otherwise they may not be aware of the free shipping option and bang goes the sale.

We have all of the shipping options showing on the Checkout Shipping page and I would like to mirror this in the Shopping Cart drop-down.

Regards

Simon Hornby

Edited by simonhornby, 14 July 2013 - 20:29.


#29   simonhornby

simonhornby

    simonhornby

  • Members
  • 21 posts
  • Real Name:Simon Hornby
  • Gender:Male
  • Location:Chester, England

Posted 16 July 2013 - 11:26

Free Shipping in order total!

Sussed! I use Royal Mail 2nd Class Standard v2.2.2 zone rates so I set shipping zone rate at 100000:003 ie to ship up to 100Kg costs 1/3p. 100kg is way more than we actually will ship so all orders should be covered. The amount (0.003) is too small for OSC to round up to 1p so is "charged" to the Customer at £0.00 - ie Free Shipping. But, because it is not actually "free" OSC shows the shipping module in checkout_shipping.

If you want to the shipping description to be "Free Shipping" instead of the module name just go into the module and alter the name string - it is really obvious where to do this once the file is open.

/biggrin.png' class='bbc_emoticon' alt=':D' />

Edited by simonhornby, 16 July 2013 - 11:33.


#30   elsantu

elsantu
  • Members
  • 6 posts
  • Real Name:Enrique

Posted 14 December 2013 - 09:46

Hi,

Can someone tell me where is my fault, the matter is final result is wrong.

<!-- calculamos el iva del envio -->
<p align="right"><?php echo TAX_ON_DELIVERY; echo $currencies->format(tep_calculate_tax((float)$calcul_fdp_scart, $tax_fdp)) . tep_draw_separator('pixel_trans.gif', '3%', '5');?></p>
<!-- mostramos el precio de los productos -->
<p align="right"><?php echo ORDER_SUBTOTAL; echo $currencies->format($cart->show_total()) . tep_draw_separator('pixel_trans.gif', '3%', '5'); ?></p>
<!-- fijamos el iva al 10% y lo mostramos en vattotal -->
<p align="right"><?php $vattotal = $currencies->format($cart->show_total()*10/100); ?><?php echo TAX_ON_PRODUCTS . $vattotal . tep_draw_separator('pixel_trans.gif', '3%', '5');?></p>
<!-- sumamos todos los conceptos -->
<p align="right"><strong><?php echo ORDER_TOTAL_APROX; echo $currencies->format(($cart->show_total()) + ((float)$calcul_fdp_scart + tep_calculate_tax((float)$calcul_fdp_scart, $tax_fdp)) + (float)$vattotal) ;?></strong></p>

#31   cinolas

cinolas
  • Members
  • 80 posts
  • Real Name:Nicolas

Posted 05 January 2014 - 00:05

Hi all,

Many thanks to Monsieur Brouillard for this contribution, it does exactly what I want.

I'm trying to make it work with the Canada Post shipping module (which gets an actual quote from the Canada Post server based on the postal code and weight) and out of the box it works nearly perfectly. My first obstacle is that when Canada Post offers several different services at various rates, the drop down menu shows them from most expensive to least expensive and the default choice is the most expensive. Obviously I'd like that to be the other way around: Showing the shipping speeds from least expensive to most expensive with the default being the least expensive.

I only use the Canada Post module and Store Pickup shipping modules

Any idea how to make that happen?

Thanks!

Edited by cinolas, 05 January 2014 - 00:10.


#32   cinolas

cinolas
  • Members
  • 80 posts
  • Real Name:Nicolas

Posted 06 January 2014 - 21:00

I've been digging into this with no success. The actual shipping page does sort the various rates correctly from cheapest to most expensive, and successfully picks the cheapest one as default choice using the cheapest() function in shipping.php

It seems to me I should be able to call this function through fdp_panier.php but the exact syntax goes beyond my understanding of php.

I'd be happy if at least the cheapest option was preselected, even if the menu is in reverse order.

Any help is greatly appreciated, thanks!



Hi all,

Many thanks to Monsieur Brouillard for this contribution, it does exactly what I want.

I'm trying to make it work with the Canada Post shipping module (which gets an actual quote from the Canada Post server based on the postal code and weight) and out of the box it works nearly perfectly. My first obstacle is that when Canada Post offers several different services at various rates, the drop down menu shows them from most expensive to least expensive and the default choice is the most expensive. Obviously I'd like that to be the other way around: Showing the shipping speeds from least expensive to most expensive with the default being the least expensive.

I only use the Canada Post module and Store Pickup shipping modules

Any idea how to make that happen?

Thanks!



#33   14steve14

14steve14
  • Members
  • 3,505 posts
  • Real Name:Steve
  • Gender:Male
  • Location:Dorset UK

Posted 07 January 2014 - 13:59

The originator of this code is still sometimes on these forums but does not seem to offer support for this any more. Its a shame really because the addon works, but has a few minor glitches that spoil it.
REMEMBER BACKUP, BACKUP AND BACKUP

Don't take life too seriously. no one gets out alive anyway

#34   cinolas

cinolas
  • Members
  • 80 posts
  • Real Name:Nicolas

Posted 15 January 2014 - 22:24

It's understandable, imagine having to provide free lifetime support for a piece of software you didn't get paid to write /smile.png' class='bbc_emoticon' alt=':)' />

Anyone else that understands how this contribution works willing to land a hand?

My problem can't be that complicated, it's almost the sort of thing I could handle with my very limited knowledge of php. Looking at the code it seems it should actually do what I want out of the box, but it's not happening. Like I said above, the shipping module itself is properly set to sort the various shipping rates correctly and auto-select the cheapest, and all of that happens properly on the shipping page, just not on the cart page.

Looking at the code here, line 82 of fdp_panier.php:

for ($i = 0; $i < sizeof($quotes); $i++) {
    for ($j = 0; $j < sizeof($quotes[$i]['methods']); $j++) {
	 if ( ($quotes[$i]['methods'][$j]['cost'] > 0) && ($order->content_type != 'virtual') ) {
		 $quotes_array[] = array('id' => $quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'], 'text' => $quotes[$i]['module'].' '.$quotes[$i]['methods'][$j]['id']);
//fixer un choix par defaut
		 $default_quotes_array[] = $quotes[$i];
		  if ( $_GET['shippingselected'] != '' ) {
			  $default_shipping_module = str_replace("'", "", $_GET['shippingselected']);
		  } elseif ( $quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'] == DEFAULT_MODE_DELIVRY_SC ) {
			  $default_shipping_module = DEFAULT_MODE_DELIVRY_SC;
		  }
// envoyé le module selctionné (shippingselected ou DEFAULT_MODE_DELIVRY_SC)
		  if ( ($quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'] == $default_shipping_module) ) {
			   $calcul_fdp_scart = $quotes[$i]['methods'][$j]['cost'];
			   $tax_fdp = $quotes[$i]['tax'];
			   $titre_shipping = $quotes[$i]['module'].' ('.$quotes[$i]['methods'][$j]['title'].')';
		  } elseif ( ($quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id']) == ($default_quotes_array[0]['id'].'_'.$default_quotes_array[0]['methods'][0]['id']) ) {
			   $calcul_fdp_scart = $quotes[$i]['methods'][$j]['cost'];
			   $tax_fdp = $quotes[$i]['tax'];
			   $titre_shipping = $quotes[$i]['module'].' ('.$quotes[$i]['methods'][$j]['title'].')';
		  }
	 }
    }
   }

This is where it's cycling through the various modules, and methods offered by each module, to build the drop down menu. It's also choosing the default option and setting the variables later used to calculate the total. Surely there's a way for me to add an IF to the default method selection so that it chooses the one with the lowest cost.

It almost looks as though the last elseif simply selects the first option in the menu, method 0. If that's the case, can I somehow specify that it should select the biggest ID of the array instead of 0. Since the methods are sorted from most expensive to least expensive, at least it'll default to the cheapest option.

Thanks for the help!

#35   Roaddoctor

Roaddoctor
  • Members
  • 1,019 posts
  • Real Name:David Jennings
  • Gender:Not Telling
  • Location:Texas

Posted 25 March 2014 - 03:39

Can someone tell me if this item supports zip/postal code lookup for US to US shipping? I am using the USPS and UPS add ons for shipping, my site is 2.3.3


Ditto - this is a beautiful thing of a add-on - very nice! .... until I see it's not set up for zip code entry on shopping cart. When logged in it works like a charm, but that's not the purpose.

Has anyone tried to ZipCode this up with success?
-Dave

#36   Roaddoctor

Roaddoctor
  • Members
  • 1,019 posts
  • Real Name:David Jennings
  • Gender:Not Telling
  • Location:Texas

Posted 25 March 2014 - 20:25

This addon is very nice. I've been trying to add the ability for a non-logged in customer to enter a zip code to retrieve quotes without having to create an account. I can fiddle with php but don't have the skills to write it. I could use some help if anyone can assist.

Basically in the existing code you can see

	 $order->delivery = array('postcode' => '',
							 'zone_id' => $default_countrie_zone_id,
							 'country' => Array( 'id' => $default_countrie_id, 'title' => '', 'iso_code_2' => $default_countrie_iso2, 'iso_code_3' => $default_countrie_iso3 ));
}

and for testing if you hard code a zip code like
	 $order->delivery = array('postcode' => '60015',

you get quotes (for that zip) without being logged in. So basically it works with just a Zip code. So how do I write a block where the guest enters a zip code, and have the page refresh with the quotes?

Lower in the code I added this, which created the fields ok, but I'm not sure if it's at all correct.
	 <p align="right" class="prixTotauxPanier"><?php if ($order->delivery['postcode'] == '') { echo TEXT_ZIPCODE . tep_draw_input_field ('postcode',$postcode, 'MAXLENGTH="20" SIZE="10" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>

entire block
<!-- soustotal fdp total -->
<?php
if ( $order->content_type != 'virtual' ) {
?>
	 <p align="left" class="msgfdpgratuitPanier"><?php echo $text_fdp_scart; ?></p>
<!--/////////// -->
	 <p align="right" class="prixTotauxPanier"><?php if ($order->delivery['postcode'] == '') { echo TEXT_ZIPCODE . tep_draw_input_field ('postcode',$postcode, 'MAXLENGTH="20" SIZE="10" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
<!--/////// -->
	 <p align="right" class="prixTotauxPanier"><?php if ($order->customer['country']['id'] == '') { echo TEXT_DELIVRY_STATE . tep_draw_pull_down_menu('countrieselected', $countries_array, $menu_default_countrie, 'width="230" style="width: 230px" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php if (sizeof($quotes_array) > 1) { echo TEXT_DELIVRY_TRANSPORTEUR . tep_draw_pull_down_menu('shippingselected', $quotes_array, $default_shipping_module, 'width="230" style="width: 230px" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php if (isset($erreur_shipping) && !isset($default_quotes_array)) { foreach ($erreur_shipping as $erreur_shipping_index => $erreur_shipping_values) { echo $erreur_shipping_values . '<br />'; } } elseif ($default_quotes_array != '') { echo ucfirst($titre_shipping); echo ' : ' . $currencies->display_price((float)$calcul_fdp_scart, $tax_fdp, 1) . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php echo SUB_TITLE_SUB_TOTAL; echo $currencies->format($cart->show_total()) . tep_draw_separator('pixel_trans.gif', '100%', '5'); ?></p>
	 <p align="right" class="prixST"><?php echo SUB_TITLE_TOTAL; echo $currencies->format(($cart->show_total()) + ((float)$calcul_fdp_scart + tep_calculate_tax((float)$calcul_fdp_scart, $tax_fdp))) ;?></p>
<?php
} else {
?>
	 <p align="right" class="prixST"><?php echo SUB_TITLE_TOTAL . $currencies->format($cart->show_total()); ?></p>
	 </tr>
<?php
}
?>

At this point is where i'm stuck. How to have the entered zip code saved into the session, and have the script use the zip code to re-execute the script, refresh page and show quotes, Any direction appreciated.

Here's the whole script WITHOUT my changes (v1.35 clean)

<?php
/*
$Id: fdp_panier.php 22 Mai 2012
by Brouillard s'embrouille (brouillard-sembrouille@laposte.net)
osCommerce, Open Source E-Commerce Solutions
http://www.oscommerce.com
Copyright (c) 2012 osCommerce
Released under the GNU General Public License
*/
//################# Frais de port dans le panier by Brouillard s'embrouille ###############
//------------------- affiche fdp ----------------------------------------------------
function get_erreur_shipping($id_erreur) {
for ($i = 0; $i < sizeof($id_erreur); $i++) {
	 if (isset($id_erreur[$i]['error'])) $erreur_array[] = $id_erreur[$i]['error'];
}
	 return $erreur_array;
}
//menu_deroulant
$countries = tep_get_countries();
for ($i = 0; $i < sizeof($countries); $i++) {
	 $countries_array[] = array('id' => $countries[$i]['countries_id'], 'text' => $countries[$i]['countries_name']);
}
//la boutique
	 $store_countrie_query = tep_db_query("select ab.entry_zone_id, c.countries_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3 from " . TABLE_COUNTRIES . " c," . TABLE_ADDRESS_BOOK . " ab left join " . TABLE_ZONES . " z on (ab.entry_zone_id = z.zone_id) where c.countries_id = '" . STORE_COUNTRY . "' group by c.countries_id");
	 $store_countrie_values = tep_db_fetch_array($store_countrie_query);
//le choix du client
	 $shipping_delivery_query = tep_db_query("select ab.entry_zone_id, c.countries_id, c.countries_name, c.countries_iso_code_2, c.countries_iso_code_3 from " . TABLE_COUNTRIES . " c," . TABLE_ADDRESS_BOOK . " ab left join " . TABLE_ZONES . " z on (ab.entry_zone_id = z.zone_id) where c.countries_id = '" . (int)tep_db_prepare_input(str_replace("'", "", $_GET['countrieselected'])) . "' group by c.countries_id");
	 $shipping_delivery_values = tep_db_fetch_array($shipping_delivery_query);
if ( $shipping_delivery_values['countries_id'] != '' ) {
	 $menu_default_countrie = $shipping_delivery_values['countries_id'];
} else {
	 $menu_default_countrie = $store_countrie_values['countries_id'];
}
require(DIR_WS_CLASSES . 'order.php');
$order = new order;
if ( $order->delivery['country']['id'] == '' ) {
	 if ( $order->customer['country']['iso_code_2'] != '' ) {
		 $default_countrie_zone_id = $order->customer['zone_id'];
		 $default_countrie_id = $order->customer['country']['id'];
		 $default_countrie_iso2 = $order->customer['country']['iso_code_2'];
		 $default_countrie_iso3 = $order->customer['country']['iso_code_3'];
	 } elseif ( $shipping_delivery_values['countries_iso_code_2'] != '' ) {
		 $default_countrie_zone_id = $shipping_delivery_values['entry_zone_id'];
		 $default_countrie_id = $shipping_delivery_values['countries_id'];
		 $default_countrie_iso2 = $shipping_delivery_values['countries_iso_code_2'];
		 $default_countrie_iso3 = $shipping_delivery_values['countries_iso_code_3'];
	 } else {
		 $default_countrie_zone_id = $store_countrie_values['entry_zone_id'];
		 $default_countrie_id = $store_countrie_values['countries_id'];
		 $default_countrie_iso2 = $store_countrie_values['countries_iso_code_2'];
		 $default_countrie_iso3 = $store_countrie_values['countries_iso_code_3'];
	 }
	 $order->delivery = array('postcode' => '',
							 'zone_id' => $default_countrie_zone_id,
							 'country' => Array( 'id' => $default_countrie_id, 'title' => '', 'iso_code_2' => $default_countrie_iso2, 'iso_code_3' => $default_countrie_iso3 ));
}
$total_count = $cart->count_contents();
$total_weight = $cart->show_weight();
require(DIR_WS_CLASSES . 'shipping.php');
$shipping_modules = new shipping;
$quotes = $shipping_modules->quote();
$erreur_shipping = get_erreur_shipping($quotes);
for ($i = 0; $i < sizeof($quotes); $i++) {
for ($j = 0; $j < sizeof($quotes[$i]['methods']); $j++) {
	 if ( ($quotes[$i]['methods'][$j]['cost'] > 0) && ($order->content_type != 'virtual') ) {
		 $quotes_array[] = array('id' => $quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'], 'text' => $quotes[$i]['module'].' '.$quotes[$i]['methods'][$j]['id']);
//fixer un choix par defaut
		 $default_quotes_array[] = $quotes[$i];
		 if ( $_GET['shippingselected'] != '' ) {
			 $default_shipping_module = str_replace("'", "", $_GET['shippingselected']);
		 } elseif ( $quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'] == DEFAULT_MODE_DELIVRY_SC ) {
			 $default_shipping_module = DEFAULT_MODE_DELIVRY_SC;
		 }
// envoyé le module selctionné (shippingselected ou DEFAULT_MODE_DELIVRY_SC)
		 if ( ($quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id'] == $default_shipping_module) ) {
			 $calcul_fdp_scart = $quotes[$i]['methods'][$j]['cost'];
			 $tax_fdp = $quotes[$i]['tax'];
			 $titre_shipping = $quotes[$i]['module'].' ('.$quotes[$i]['methods'][$j]['title'].')';
		 } elseif ( ($quotes[$i]['id'].'_'.$quotes[$i]['methods'][$j]['id']) == ($default_quotes_array[0]['id'].'_'.$default_quotes_array[0]['methods'][0]['id']) ) {
			 $calcul_fdp_scart = $quotes[$i]['methods'][$j]['cost'];
			 $tax_fdp = $quotes[$i]['tax'];
			 $titre_shipping = $quotes[$i]['module'].' ('.$quotes[$i]['methods'][$j]['title'].')';
		 }
	 }
}
}
//------------------- fin affiche fdp ----------------------------------------------------
//---------------------- message et calcul free shipping ----------------------------
//client(e) connecté(e)
$customer_sendto_country_query = tep_db_query("select entry_country_id from " . TABLE_ADDRESS_BOOK . " where address_book_id = '" . (int)$sendto . "'");
$customer_sendto_country_values = tep_db_fetch_array($customer_sendto_country_query);
if ($customer_sendto_country_values['entry_country_id'] != '') {
	 $customer_sendto_country_id = $customer_sendto_country_values['entry_country_id'];
} elseif ( $order->customer['country']['id'] != '' ) {
	 $customer_sendto_country_id = $order->customer['country']['id'];
} elseif ( $shipping_delivery_values['countries_id'] != '' ) {
	 $customer_sendto_country_id = $shipping_delivery_values['countries_id'];
} else {
	 $customer_sendto_country_id = STORE_COUNTRY;
}
if ( defined('MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING') && (MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING == 'true') ) {
$shopping_cart_pass = 0;
switch (MODULE_ORDER_TOTAL_SHIPPING_DESTINATION) {
	 case 'national':
	 if ($customer_sendto_country_id == STORE_COUNTRY) {
		 $shopping_cart_pass = 1;
	 }
	 break;
	 case 'international':
	 if ($customer_sendto_country_id != STORE_COUNTRY) {
		 $shopping_cart_pass = 1;
	 }
	 break;
	 case 'both':
	 $shopping_cart_pass = 1;
	 break;
}
$fdp_max_scart = MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER;
$fdp_gratuit_scart = ((float)$fdp_max_scart)-((float)$cart->show_total());
if ( ($shopping_cart_pass == 1) && ($cart->show_total() >= MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER) ) {
		 $text_fdp_scart = TEXT_FREE_SHIPPING;
		 $calcul_fdp_scart = 0;
	 } elseif ( ($shopping_cart_pass == 1) && ($cart->show_total() < MODULE_ORDER_TOTAL_SHIPPING_FREE_SHIPPING_OVER) ) {
		 $text_fdp_scart = sprintf(TEXT_REST_FREE_SHIPPING, $currencies->format($fdp_gratuit_scart)) . ' ' . $currencies->format(0);
	 }
}
// --------------------- fin message et calcul free shipping -------------------
?>
<!-- soustotal fdp total -->
<?php
if ( $order->content_type != 'virtual' ) {
?>
	 <p align="left" class="msgfdpgratuitPanier"><?php echo $text_fdp_scart; ?></p>
	 <p align="right" class="prixTotauxPanier"><?php if ($order->customer['country']['id'] == '') { echo TEXT_DELIVRY_STATE . tep_draw_pull_down_menu('countrieselected', $countries_array, $menu_default_countrie, 'width="230" style="width: 230px" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php if (sizeof($quotes_array) > 1) { echo TEXT_DELIVRY_TRANSPORTEUR . tep_draw_pull_down_menu('shippingselected', $quotes_array, $default_shipping_module, 'width="230" style="width: 230px" onchange="this.form.submit();"') . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php if (isset($erreur_shipping) && !isset($default_quotes_array)) { foreach ($erreur_shipping as $erreur_shipping_index => $erreur_shipping_values) { echo $erreur_shipping_values . '<br />'; } } elseif ($default_quotes_array != '') { echo ucfirst($titre_shipping); echo ' : ' . $currencies->display_price((float)$calcul_fdp_scart, $tax_fdp, 1) . tep_draw_separator('pixel_trans.gif', '100%', '5'); } ?></p>
	 <p align="right" class="prixTotauxPanier"><?php echo SUB_TITLE_SUB_TOTAL; echo $currencies->format($cart->show_total()) . tep_draw_separator('pixel_trans.gif', '100%', '5'); ?></p>
	 <p align="right" class="prixST"><?php echo SUB_TITLE_TOTAL; echo $currencies->format(($cart->show_total()) + ((float)$calcul_fdp_scart + tep_calculate_tax((float)$calcul_fdp_scart, $tax_fdp))) ;?></p>
<?php
} else {
?>
	 <p align="right" class="prixST"><?php echo SUB_TITLE_TOTAL . $currencies->format($cart->show_total()); ?></p>
	 </tr>
<?php
}
?>
<!-- fin soustotal fdp total -->
<!-- //############ Fin Frais de port dans le panier by Brouillard s'embrouille ############-->

Thank you in advance! This is an awesome sleek add-on for 2.3+ and should be very popular once sorted.

Dave

shipping methods I am using are fedexwebservices and flatrate
-Dave

#37   Peper

Peper
  • Members
  • 382 posts
  • Real Name:Pierre
  • Gender:Male
  • Location:South Africa

Posted 23 July 2014 - 11:30

Anyone got this to show TAX. 

Currently showing all pricing ex TAX

 

And also to show in order like:

Shipping cost:

Subtotal:

Tax

Total:


Contributions successfully installed : Header tags SEO, Scrolling new products, Customer testimonials, Support tickets, Polls, Link exchange, SPPC, X-sell, Master products, Dhtml menu, Image cache, Slide show, Product videos, Product custom sort, Product notes, Discount coupons, Ask question(review style + admin), CP builder, Customers also purchased, price list, // SEO URLS 5, and forgot the others and then a real admin setup.