uShop English (U.S.) for 179!

uStorekeeper English (U.S.) for 149!

 Products
       uTest
       uReserve
       uShop
       uStorekeeper
       uGolf
       uDirectory
       uSignIn
 Tech Support
       Support Policy
       Knowledge Base
            uTest
            uReserve
            uShop
            uStorekeeper
            uGolf
            uDirectory
            uSignIn
       Documentation
       Reference Sites
 Legal
       Software Piracy
       Legal Notices
       Privacy Policy
       Licensing
 Miscellaneous
       Reseller Info
       Contact Us
       Site Map
tax added in COD payment option with 3.4

Knowledge Base Lobby : uShop Support Conference : Tax, Shipping, and Handling Questions
Nov-20-17 12:52 AM EST
Original Message
tax added in COD payment option with 3.4
Author Carsten Kraemer on 02-18-2002 at 05:15 (EST)
Hello there,

the "COD" (a.k.a. "Nachnahme") payment option does add the tax to the total even is I set the tax to be included in the ushop-lib in 3.4.

Need help here.

Carsten Krämer
E-MAIL AUTHOR | TABLE OF CONTENTS

Table Of Contents
  RE: tax added in COD payment option with 3.4 Bill Weiner, 2002-02-18 06:20:51 (1)
            not what I mean Carsten Krämer, 2002-02-18 16:23:27 (2)
                 RE: not what I mean Bill Weiner, 2002-02-19 05:39:44 (3)
                      not really fixed my problem Carsten Kraemer, 2002-02-19 06:53:44 (4)
                           RE: not really fixed my problem Bill Weiner, 2002-02-20 05:42:33 (5)
                                changed something in the script Carsten Kraemer, 2002-03-03 10:15:24 (6)
                                     RE: changed something in the script Bill Weiner, 2002-03-03 21:15:41 (7)

Messages In This Discussion
         1. RE: tax added in COD payment option with 3.4
        Author Bill Weiner on 02-18-2002 at 06:20 (EST)
If you want the "COD" and shipping charges taxed, you must set the "Tax Shipping Charge" field to "YES". So on the uShop Control Panel, under GENERAL SETTINGS - TAXES & SHIPPING, make sure the "Tax Shipping Charge:" field is set ot "YES".
TABLE OF CONTENTS
                 2. not what I mean
                Author Carsten Krämer on 02-18-2002 at 16:23 (EST)
Hello,

that's not what I meant. I have the entire tax added to the totals, although i set the tax up to be included. This just happens in the COD payment option.
TABLE OF CONTENTS
                         3. RE: not what I mean
                        Author Bill Weiner on 02-19-2002 at 05:39 (EST)
Ok, I think I understand. Here are some instructions to make sure that COD is not taxed when using the $tax_inclusive option:

STEP 1: Make a backup of your ushop.pl script... just in case.

STEP 2: Open the ushop.pl file with any text editor such as WordPad.

STEP 3: Do a search on the following line:

# Update Tax Totals.

STEP 4: About 3 lines down from there you will see two long lines beginning with:

$totals_tax =
$totals_tax_with_shipping =

(I didn't post the entire lines because they are long and wouldn't show up right in this forum)

STEP 5: IMMEDIATELY AFTER those two lines add these 5 lines:

if ($tax_inclusive =~ /yes/i)
{
$totals_tax = 0.0;
$totals_tax_with_shipping = 0.0;
}

STEP 6: Save the file ... as TEXT if your editor asks... and try it out!

Good luck!
TABLE OF CONTENTS
                                 4. not really fixed my problem
                                Author Carsten Kraemer on 02-19-2002 at 06:53 (EST)
Hello again and thank you for your fast response.

But this modification did not really fix the problem. Now I do have the right totals, but with a tax of 0 Euro.
I want to display the right tax, but I do not want the tax to be added to the totals.

Example

I purchase an item of 100 EUR:

That's how I want it:
1 Item 100 EUR


Subtotal: 100 EUR
Tax 10%: 10 EUR

Total: 100 EUR


That's how it was:
1 Item 100 EUR


Subtotal: 100 EUR
Tax 10%: 10 EUR

Total: 110 EUR


That's how it is now:
1 Item 100 EUR


Subtotal: 100 EUR
Tax 10%: 0 EUR

Total: 100 EUR


Thanks again
Carsten Krämer
TABLE OF CONTENTS
                                         5. RE: not really fixed my problem
                                        Author Bill Weiner on 02-20-2002 at 05:42 (EST)
I'm still not totally sure what you want.... because the COD fee actually gets added to the "Shipping & Handling" fee and I don't see that in your example. Also, I'm not sure if you want the "Shipping & Handling" fee taxed or not. If you could expand on your example a little more to show:

BEFORE THE COD FEE IS ADDED:
Subtotal:
Tax 10%:
Shipping & Handling:
Total:

AFTER THE COD FEE IS ADDED:
Subtotal:
Tax 10%:
Shipping & Handling & COD:
Total:

... I think that would give me enough information to understand the calculations you're looking for.

It kind of sounds like you can just comment out all four of the lines in the afformentioned "# Update Tax Totals" section of the ushop.pl script....so that the tax rate is not modified at all in the final step of the COD order process. In fact, if you just take a look at that whole:

($payment_method eq "cod_payment")

section in the ushop.pl script, you should be able to see for yourself where the totals are getting updated with the COD fee... and should be able to just comment out (by putting a # sign in front) any values that you don't want updated after the COD fee is added in.

Otherwise, complete the "BEFORE" and "AFTER" example that I listed above and I should be able to understand what fields you want updated.
TABLE OF CONTENTS
                                                 6. changed something in the script
                                                Author Carsten Kraemer on 03-03-2002 at 10:15 (EST)
Hi again,

(changed the script to meet my requirements - it works now, but more like a workaround)

well right, the COD is supposed to be added to Shipping and Handling fees, but I don't want the tax to be added to the total, because I have the tax already included.

Your example:

BEFORE THE COD FEE IS ADDED:
Subtotal: 100 EUR
Tax 10%: 10 EUR
S+H: 6 EUR
Total: 106 EUR

AFTER THE COD FEE IS ADDED the way I want it:
Subtotal: 100 EUR
Tax 10%: 10 EUR
S+H: 9 EUR
Total: 109 EUR

AFTER THE COD FEE IS ADDED the way it was
Subtotal: 100 EUR
Tax 10%: 10 EUR
S+H: 9 EUR
Total: 119 EUR
(the tax is added, although I set it up to be inclusive. This is just in the COD payment.)

I just erased the "+ totals_tax_with_shipping +" and "+ totals_tax +" in the "Update Grand Totals" section after "if cod modifier <0.0" in ushop.pl.

Carsten Krämer
TABLE OF CONTENTS
                                                         7. RE: changed something in the script
                                                        Author Bill Weiner on 03-03-2002 at 21:15 (EST)
Good. I'm glad you figured out a solution.
TABLE OF CONTENTS

© 2003 Microburst Technologies, Inc.