Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Help!!


bongo

Recommended Posts

I got a real problem..

When a customer buys a product the price is with taxes, but when the customer logging in to buy the products the tax dissapear from the price.

 

Is there somenone that can help me with this??

Link to comment
Share on other sites

You need to take a look at how your zones are set up - make sure the taxes are set to the right one. When the customer logs in osCommerce realized that he is not in the zone where tax is charged, so the taxes go away.

Chris Dunning

osCommerce, Contributions Moderator Team

 

Please do not send me PM! I do not read or answer these often. Use the email button instead!

 

I do NOT support contributions other than my own. Emails asking for support on other people's contributions will be ignored. Ask in the forum or contact the contribution author directly.

Link to comment
Share on other sites

Yeah, there's a four/five liner, you can steal from my site, goto the index Here and look through the source, it's really really transparent.!!!

 

 

Oh, here's an example without variables!!

 

<script type="text/javascript">

price = "?255.24"

price = price.substr( 1 )

price *= 1.175

price = Math.ceil( price * 100 ) / 100

pounds = Math.floor( price );

tenths = Math.floor( price * 10 ) % 10;

hundredths = Math.floor( price * 100 ) % 10;

document.write( "Price (inc VAT) ?" + pounds + "." );

document.write( tenths );

document.write( hundredths );

</script>

 

 

BUT IT ONLY works fro rpcies less than ?1000 or $1000 dollar, you know what I mean. You can fix i though.

Link to comment
Share on other sites

Thanks for the help.

 

I have tried to get your code to work but i havent figured out how to get the price into the code.

And i dont uses ? or $ i uses KR (Norsk) Does it work on that to??

 

Regards

Thomas

Link to comment
Share on other sites

It shouldn't matter what currency you're using. To input variable prices into there, you'll have to use something like $product_info['products_price'] as your variable. The exact wording of that varies depending on which file you're using. Try to find another place in that same file where the price is listed, then copy and paste.

Chris Dunning

osCommerce, Contributions Moderator Team

 

Please do not send me PM! I do not read or answer these often. Use the email button instead!

 

I do NOT support contributions other than my own. Emails asking for support on other people's contributions will be ignored. Ask in the forum or contact the contribution author directly.

Link to comment
Share on other sites

I figured it out, but the calculation doesnt work for me.

 

This is what i have wrote

 

<script type="text/javascript">

price = "<?php echo $product_info['products_price']; ?>"

price = price.substr( 1 )

price *=1.24

price = Math.ceil( price * 100 ) / 100

pounds = Math.floor( price );

tenths = Math.floor( price * 10 ) % 10;

hundredths = Math.floor( price * 100 ) % 10;

document.write( "Price (inc VAT) ?" + pounds + "." );

document.write( tenths );

document.write( hundredths );

</script>

 

If the price is 1040 ecsl vat the price inc vat is ?50.01

But this isnt right its 1290. What is wrong here?

 

Thanks for all the help i get from you..

Link to comment
Share on other sites

  • 4 weeks later...

Display Prices with Tax is set to true

 

When a person browses the site as a guest, the tax prices appear correctly. But, when they login as a Canadian customer(I followed the Canada Tax Zones Setup contribution), all the taxes dissapear. I followed the setup three times and i'm certain I followed it precisely. For more information, check my posts in

http://www.oscommerce.com/forums/index.php?showtopic=39636&st=20

 

Thanks

Link to comment
Share on other sites

Jack,

If you have tax zones setup when you look at them in admin you should see a folder at the left edge of each tax zone line you have created. Click on that folder, when it opens if it is empty(no lines) click insert and supply the data, update, go back. Do that for each tax zone you have.

Link to comment
Share on other sites

bloodshoteyes, i've already done that.

For Canada GST Zone

 

- Country: Canada; Zone: Alberta

- Country: Canada; Zone: British Columbia

- Country: Canada; Zone: Manitoba

- Country: Canada; Zone: Northwest Territories

- Country: Canada; Zone: Nunavut

- Country: Canada; Zone: Ontario

- Country: Canada; Zone: Prince Edward Island

- Country: Canada; Zone: Quebec

- Country: Canada; Zone: Saskatchewan

- Country: Canada; Zone: Yukon Territory

 

For Ontario PST Zone

- Country: Canada

- Zone: Ontario

 

and for HST Tax Zone

- Country: Canada; Zone: Nova Scotia

- Country: Canada; Zone: New Brunswick

- Country: Canada; Zone: Newfoundland

 

I've also added the classes and rates. Then I added the class to the product.

 

Any other ideas?

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...