osCommerce and osCMax shopping cart software forums

Shopping Cart Software

osCommerce with teeth!

 

Tax is lost at checkout if product weight is zero

This is a discussion on Tax is lost at checkout if product weight is zero within the osCMax v1.7 Installation forums, part of the osCMax v1.7 Forums category; I don't want to update each product with a weight as shipping will be free/included in the price, but I ...


Go Back   osCommerce and osCMax shopping cart software forums > osCMax v1.7 Forums > osCMax v1.7 Installation

Register FAQ Members List Calendar Mark Forums Read


Free community membership! Fast easy FREE membership
Closed Thread

 

LinkBack Thread Tools
  #1  
Old 07-10-2004, 08:25 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default Tax is lost at checkout if product weight is zero

I don't want to update each product with a weight as shipping will be free/included in the price, but I am finding that the products are being determined as 'virtual' in class shopping_cart, the shopping_cart page is therefore bypassing the delivery page (checkout_shipping), and the tax is lost:
in class order when called from checkout_payment
tax_address[entry_country_id] = null
tax_address[entry_zone_id] = null

but they are correct (222 and 1 respectively) if the product has a weight.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #2  
Old 07-10-2004, 09:27 AM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

The problem seems to start class order when it is called from checkout_payment
Code:
      $tax_address_query = tep_db_query("select ab.entry_country_id, ab.entry_zone_id from " . TABLE_ADDRESS_BOOK . " ab left join " . TABLE_ZONES . " z on (ab.entry_zone_id = z.zone_id) where ab.customers_id = '" . (int)$customer_id . "' and ab.address_book_id = '" . (int)($this->content_type == 'virtual' ? $billto : $sendto) . "'");
      $tax_address = tep_db_fetch_array($tax_address_query);
In the above sql ab.address_book_id returns as 6 when called from checkout_shipping but is 0 when called from checkout_payment.

The result of ($this->content_type == 'virtual' ? $billto : $sendto) is 6 when called from checkout_shipping and is empty when called from checkout_payment.

checkout_shipping
---------------------
billto: 6
sendto: 6
this->content_type: virtual_weight
products_tax: 17.5

checkout_payment
---------------------
billto: 6
sendto:
this->content_type: virtual_weight
products_tax: 0

So the sendto id is being lost!

In checkout_shipping $sendto = $customer_default_address_id but it is not set in checkout_payment. Checkout_shipping offers an address selection, so if that page is bypassed surely in checkout_payment if $sendto is empty it should be set to:
Code:
$sendto = $customer_default_address_id;
[/code]
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #3  
Old 07-29-2004, 08:05 AM
Anonymous
Guest
 
Posts: n/a
Default Same for me

Hi,
I am VERY interested to know if you find the way to fix your problem, as I have the same one and I a looking for the fix for 2 days, looking at the code.
Is there any erlation with the weight of the product ?
Thanks so much if you can help me,
Philippe
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #4  
Old 07-29-2004, 01:48 PM
Member
 
Join Date: Aug 2003
Location: Southampton UK
Posts: 63
Thanks: 0
Thanked 0 Times in 0 Posts
Rep Power: 0
NickW
Default

In checkout_payment.php around line 68 and before the line '$order = new order;' I inserted the following line:
Quote:
if ($sendto == '') {$sendto = $customer_default_address_id;}
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
  #5  
Old 08-10-2004, 03:09 AM
Anonymous
Guest
 
Posts: n/a
Default

Thanks for your reply, this can be a bypass. I will give it a try.
Philippe
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Closed Thread

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Similar Threads

Thread Thread Starter Forum Replies Last Post
Downloadable product error on checkout robfor osCMax v2 Features Discussion 2 05-20-2006 04:23 AM
Product info lost after update mgrooten osCMax v1.7 Discussion 0 08-06-2005 12:59 PM
Product weight Kalpesh osCommerce 2.2 Modification Help 0 01-03-2005 10:59 AM
Best way of controlling (max one product at checkout) Anonymous osCMax v1.7 Discussion 2 03-30-2004 02:33 AM
pricing tweks on product info page and checkout cvc505 osCommerce 2.2 Installation Help 0 06-28-2003 05:01 AM


All times are GMT -8. The time now is 09:32 AM.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO
http://www.oscmax.com/forums/
Copyright 2008 osCMax