Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

[TAX]Subtotal lists prices whit tax


Sen

Recommended Posts

Everywhere there are prices whit tax. Thats fine whit me. But @ the end of the order we got

 

Sub-total: ?200

Shipment: ?10

Tax: ?21

Total: ?210

 

But i want the sub total whitout tax. Is that possible :?

 

Thanx in advance :)

Link to comment
Share on other sites

The only way of showing the subtotal without tax is:

 

1) set define('DISPLAY_PRICE_WITH_TAX', true); to

define('DISPLAY_PRICE_WITH_TAX', false)

 

But I think you know this already!

 

C

Link to comment
Share on other sites

The only way of showing the subtotal without tax is:

 

1) set define('DISPLAY_PRICE_WITH_TAX', true); to

define('DISPLAY_PRICE_WITH_TAX', false)

 

But I think you know this already!

 

C

 

yup and that i don't want

Link to comment
Share on other sites

This looks hopefull, but I've not looked into it enough...

 

// class methods

   function format($number, $calculate_currency_value = true, $currency_type = '', $currency_value = '') {

     global $currency;



     if ($currency_type == '') {

       $currency_type = $currency;

     }



     if ($calculate_currency_value) {

       $rate = ($currency_value) ? $currency_value : $this->currencies[$currency_type]['value'];

       $format_string = $this->currencies[$currency_type]['symbol_left'] . number_format($number * $rate, $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

// if the selected currency is in the european euro-conversion and the default currency is euro,

// the currency will displayed in the national currency and euro currency

       if ( (DEFAULT_CURRENCY == 'EUR') && ($currency_type == 'DEM' || $currency_type == 'BEF' || $currency_type == 'LUF' || $currency_type == 'ESP' || $currency_type == 'FRF' || $currency_type == 'IEP' || $currency_type == 'ITL' || $currency_type == 'NLG' || $currency_type == 'ATS' || $currency_type == 'PTE' || $currency_type == 'FIM' || $currency_type == 'GRD') ) {

         $format_string .= ' <small>[' . $this->format($number, true, 'EUR') . ']</small>';

       }

     } else {

       $format_string = $this->currencies[$currency_type]['symbol_left'] . number_format($number, $this->currencies[$currency_type]['decimal_places'], $this->currencies[$currency_type]['decimal_point'], $this->currencies[$currency_type]['thousands_point']) . $this->currencies[$currency_type]['symbol_right'];

     }



     return $format_string;

   }



   function get_value($code) {

     return $this->currencies[$code]['value'];

   }



   function display_price($products_price, $products_tax, $quantity = 1) {

     return $this->format(tep_add_tax($products_price, $products_tax) * $quantity);

 

C

Link to comment
Share on other sites

It's in catalog/includes/classes/currencies.php

 

I think this is the function that does the money calculations, therefore maybe you could take tax from the total some how!!

 

I might get to this, if I do I'll buzz you!

 

C

Link to comment
Share on other sites

  • 1 year later...

After searching a lot I found an anwer to this problem.

 

The module order_total takes care of what is displayed.

 

In the file ot_subtotal.php (folder order_totals) you have to make some changes.

 

Somewhere around line 29 you should make the following changes to the function process()

 

 

function process() {

global $order, $currencies;

 

 

$this->output[] = array('title' => $this->title . ':',

// Edited 14-04-04 by Mike MKEhosting.com for display without tax in the subtotal at checkout_confirmation.

// Original 'text' => $currencies->format($order->info['subtotal'], true, $order->info['currency'], $order->info['currency_value']),

'text' => $currencies->format(($order->info['subtotal'])-($order->info['tax']), true, $order->info['currency'], $order->info['currency_value']),

// Original 'value' => $order->info['subtotal']);

'value' => ($order->info['subtotal'])-($order->info['tax']));

}

 

I tried it and it seems to work.

Hope it helps.

Link to comment
Share on other sites

  • 9 months later...

Hello,

 

I need advise.

 

 

Currently in my store tax gets calculated on shipping charges rather then subtotal. How can i take care of this issue?

 

When its flat rate shipping. Things works fine. But I change it to UPS shipping and not tax is getting calculated on shipping charge.

 

Please advise.

 

Pitu

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...