The Foxy forums are on the move!

We're in the process of moving our forums over to a new system, and so these forums are now read-only.
If you have a question about your store in the meantime, please don't hesitate to reach out to us via email.

Tax not calculated correctly on checkout page load

nathanpitmannathanpitman Member
in Bugs & Feature Requests edited August 2010
I'm seeing issues with tax not being correctly calculated on the checkout page at load time. For example if I checkout with a product priced at $20 with UK VAT (17.5%) applied I'm quoted VAT of $1.75! However if I proceed to pay the VAT is then correctly calculated on the receipt page.

I've tried switching back from my custom checkout template to the standard FoxyCart template but the problem still persists. Any ideas?
  • lukeluke FoxyCart Team
    The tax should calculate as soon as you put in all of the billing contact information needed to calculate the tax. We've improved this in the next version with a "TBD" value instead of "0" so it's not so confusing. Is that the only problem? Once you put in the contact info, does the correct tax show up? Which store is this for so we can take a look?
  • I'm using SSO with FoxyCart (via Foxee) so the billing details are all pre-populated in advance. Perhaps you could take a look for me if I whisper you the URL?
  • lukeluke FoxyCart Team
    Yeah, looks ok to me. Might be that the product is priced as $9.99 and not $20 as you expect.
  • This is odd, I tried it again this AM and it still calculated the tax incorrectly, then I started overtyping the country field and re-selected United Kingdom from the JavaScript select on the checkout page, once I did this the tax amount was corrected. I then cancelled, emptied my basket and tried again with two other user accounts and the tax was calculated correctly in both cases. Odd!

    Is there any chance that when testing and using the one same account that data can get cached locally in varying states and cause issues like this?
  • lukeluke FoxyCart Team
    It's not something we've heard of before... unless the SSO integration (FoxEE?) is sending more information along or storing that in a cookie/session or something? Very strange. Unless we can reproduce it, it's not something we can fix.
  • Ok, I've found the pattern here. Basically the checkout page is caching the VAT amount as per the previous attempted checkout. So for example add an item with a price of $20 to your basket, go to checkout (VAT is correctly calculated as $3.50) and then cancel and return (this empties your basket). If you then add an item with a price of $10 to your basket and go to checkout the page initially shows a VAT amount of $3.50, if I hard refresh the checkout page this corrects itself and displays as $1.75. So... it looks like the checkout page is stuck in my browser cache, is this something you've seen before and how should I prevent it from occurring! :)
  • Just wondered, would adding the following to my checkout template solve the problem?
    <meta http-equiv='cache-control' content='no-cache'>
    <meta http-equiv='expires' content='0'>
    <meta http-equiv='pragma' content='no-cache'>
  • lukeluke FoxyCart Team
    If it solves the problem, then yes. :) I'm honestly not sure... I probably do way too much development with cache completely turned off to recognize issues like this. We'll talk about it internally but if the problem goes away, that sounds like a good solution.
  • Tried this, didn't solve the problem.., I think this needs to be logged as a bug as I've checked both with my custom checkout template and the standard checkout template, the pattern is reproducible in both cases. :(

    This is going to be a real problem if there's no resolution as our users are going to see the incorrect VAT calculation pretty much any time they purchase something from us... :/
  • ok, some further investigation.. this problem doesn't appear to occur at all in Safari 5 on OS X. My previous tests had all been with Firefox 3.6.8 on OS X. I'm going to see if I can force a restore defaults in FF to make sure it's not some spurious setting somewhere causing the problem...
  • lukeluke FoxyCart Team
    Definitely seems like a strange one since it hasn't come up before. Do you have any other interesting things going on like multiship, single sign on integration or checkout template javascript hacks?
  • brettbrett FoxyCart Team
    Nathan, can you whisper one of us step by step instructions to see this? I just tested using the info you whispered earlier and I'm not seeing _any_ VAT, so I must be missing something.
  • Hi guys, I've completely removed Firefox from my Mac and re-installed and have been able to reproduce this again so it seems to be a FF issue (on OS X at least) but I've yet to check if it's also an issue on Windows or with IE. I'll whisper you complete step by step instructions. :)
  • @luke We're using Foxee and have SSO enabled but that's about it... it's just a standard item purchase other than that. I did try reverting back to the standard FoxyCart checkout template but the problem persisted so I'm confident it's nothing to do with my checkout template code. If you want to switch back to the standard template yourselves to check though do feel free. :)
  • brettbrett FoxyCart Team
    Thx for the details. I definitely see this happening now.

    Yeah, that definitely looks like an issue on our end. We'll take a look.
  • Brill, glad I'm not going mad. Let me know when you have a fix. :)
  • Any news on this guys, it's going to be a show-stopper for us and our client if it can't be resolved. :/
  • lukeluke FoxyCart Team
    edited August 2010
    Hey nathan. We're still discussing this internally. Please ping back if you don't hear from us within a few days.

    Oh, also, have you tried upgrading to 070? I'm not sure what changes on the FoxEE side need to happen to support 070, but I'm curious if that might solve this issue or not.

    For what it's worth, I haven't been able to reproduce this in FF 3.6.8 on Windows 7.
  • brettbrett FoxyCart Team
    Nathan, can you re-link us to step through the process? The previous links you whispered don't work anymore, but we really do want to get this sorted out.
  • lukeluke FoxyCart Team
    Thanks Nathan. We just rolled a fix for this. We had some trouble reproducing it on our end until Brett reinstalled a fresh browser from scratch. That got me thinking that my plugins like Firebug and Webdev tool bar might be interfering with the process. When I disabled both of them I was able to reproduce it and come up with a fix to ensure the tax ajax request isn't cached. It seems to be working now from what I can tell.
  • Wow, fixed. Brilliant. Thanks ever so much for your help with this, great to have it squashed from our internal bug list. :)
Sign In or Register to comment.