Jump to:

17452 Posts in 4473 Topics by 1971 members

Archive

SilverStripe Forums » Archive » E-commerce tax calculation - cannot set up - Fatal Error

Our old forums are still available as a read-only archive.

Moderators: martimiz, Sean, biapar, Willr, Ingo, simon_w

Page: 1
Go to End
Author Topic: 946 Views
  • Pixel
    Avatar
    Community Member
    78 Posts

    E-commerce tax calculation - cannot set up - Fatal Error Link to this post

    I have been having ongoing difficulty in setting up the ecommerce module.

    My clients wish to add tax to their orders and so i added this snippet of code word for word from the ecommerce documentation to the mysites/_config.php:

    TaxCalculator::set_for_country("UK", 0.175, "VAT", "exclusive");

    However I get this fatal error:

    Fatal error: Class 'TaxCalculator' not found in /var/www/vhosts/mysite.co.uk/httpdocs/mysite/_config.php on line 38

    Why does it not work!!?

    If i put:

    TaxModifier::set_for_country("UK", 0.175, "VAT", "exclusive");

    the fatal error goes but nothing seems to happen

    Help please

  • Pixel
    Avatar
    Community Member
    78 Posts

    Re: E-commerce tax calculation - cannot set up - Fatal Error Link to this post

    Ok i still have had no luck with implementing the TaxCalculator.

    The only workaround that I can think of now is to include tax in the prices and then show the net prices in the product description.

    Unless someone knows otherwise.

    946 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.