cYon Posted February 20, 2004 Posted February 20, 2004 I just got my site up and running and I have had a few orders placed using PayPal as the payment method and it is NOT adding the shipping fee's to the order. They are only paying the sub-total. No Shipping fee's are being calculated. The items I'm shipping cost from $10-$20 per item so I'm losing big time here. Anyone have any clue? When your at the confirmation page and click confirm order it shows the total cost including shipping fees, however, when you get to the PayPal page shipping fees are not included. Someone pleaseeeeee help me out!!!
cYon Posted February 20, 2004 Author Posted February 20, 2004 Well, it seems the problem is on the paypal end, OSC is sending the amount and shipping cost, however, paypal is not adding shipping cost to the total. So I modified the paypal.php module to include the shipping costs in the amount so I don't lose out on shipping costs. Here is what I changed incase this can help someone else: Find the following line in /includes/modules/payment/paypal.php tep_draw_hidden_field('amount', number_format(($order->info['total'] - $order->info['shipping_cost']) * $currencies->get_value($my_currency), $currencies->get_decimal_places($my_currency))) . Change the line to: tep_draw_hidden_field('amount', number_format(($order->info['total'] + $order->info['shipping_cost']) * $currencies->get_value($my_currency), $currencies->get_decimal_places($my_currency)) - $order->info['shipping_cost']) . You may look at the code and ask why subtract the shipping cost from the amount after you already added the shipping costs. Well, for some reason (I did not looking any further, as the code I modified gave me the desired result) when adding the shipping cost to the amount it added double the shipping cost, so I had to subtract the shipping cost to get the accurate total. Anyhow, it's ugly, but worked for me.
cYon Posted February 20, 2004 Author Posted February 20, 2004 Ignore the above code, the problem was an issue with my PayPal settings, so the above code is not needed!
Recommended Posts
Archived
This topic is now archived and is closed to further replies.