Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Paypal Express - Seen New Error - Help Please


Mort-lemur

Recommended Posts

@@Harald Ponce de Leon Not attributes - I set up a test product without any attributes with the net of 8.32 and the same problem - it seems to only occur whe the gross prices are to 3 decimal places where multiples of the product make the third decimal place greater than 5 hence the rounding up - if I set the gross price to 9.980 rather than 9.984 then everything is ok as it should be

 

But the strange thing is when I go through the full checkout process (rather than PP Express from shopping_cart) the subtotal is shown as 19.97, the shipping as 2.98 BUT the order total is 22.94 as it should be.

 

So this is leading me to think that its something in the way my sub totals are calculated

Edited by Mort-lemur

Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.

Link to comment
Share on other sites

@@Mort-lemur I've just buzzed through your older thread where you added loads of addons, but didn't see any addon that could (at first glance) cause subtotal issues. There is mention of some order_total changes you made...but not much detail on it so cannot say if that is the culprit.

Link to comment
Share on other sites

Thanks Gary I will go back and take a look at that see if I can remember what changes I made

 

Harald I have sent you a link so you can see the behaviour

Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.

Link to comment
Share on other sites

where is the subtotal calculated?

Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.

Link to comment
Share on other sites

yep I have that line in my shopping_cart.php and it is not modified :

    <p align="right"><strong><?php echo SUB_TITLE_SUB_TOTAL; ?> <?php echo $currencies->format($cart->show_total()); ?></strong></p>

and in includes/classes/shopping_cart.php I have:

    function show_total() {
      $this->calculate();

      return $this->total;
    }

Now running on a fully modded, Mobile Friendly 2.3.4 Store with the Excellent MTS installed - See my profile for the mods installed ..... So much thanks for all the help given along the way by forum members.

Link to comment
Share on other sites

Keep on tracking back through;

 

$this->calculate(); == function calculate -in the same file (compare this to a stock 2.3.4)

 

in that function you'll find other functions (eg: tep_round and so on). Find these functions and compare to a stock 234).

 

Something somewhere is causing issues for you..

Link to comment
Share on other sites

I just had a look at her files and there was a customization performed in currencies->calculate_price() that rounded the price to 10 decimal points instead of the currency decimal points value.

 

That would explain the rounding issue.

:heart:, osCommerce

Link to comment
Share on other sites

  • 6 months later...
  • 1 year later...

Hi Harald,

 

I don't think this is as clear cut as you think.  I'm unfortunately suffering from this problem too on a production site and to test it wasn't any addons/customisations I've loaded a brand new 2.3.4 install without any addons/customisations.

 

Please see here http://www.oscommerce.com/forums/topic/409406-oscommerce-bug-brand-new-234-install-without-customisationsaddons/

If it still don't work, hit it again!

Senior PHP Dev with 18+ years of commercial experience for hire, all requirements considered, see profile for more information.

Is your version of osC up to date? You'll find the latest osC version (the community-supported responsive version) here.

Link to comment
Share on other sites

I occasionally get a discrepancy if:

 

1. the item price was input to the store in the including tax box.

2. the excluding tax price is then 3 odd digits,

 

I think it is down to which way the rounding happens and the tax calculated by the shop and paypal.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...