Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Paypal Pro receives order total without handling fee


baalwww

Recommended Posts

I have my admin set to add a handling fee of $5. I received my first order since, and the order info on OSC shows the handling fee, and an order total that includes the handling fee. The order amount passed to Paypal Pro, and thus the amount charged to the customer, did not include the $5. HELP!

Link to comment
Share on other sites

I have my admin set to add a handling fee of $5. I received my first order since, and the order info on OSC shows the handling fee, and an order total that includes the handling fee. The order amount passed to Paypal Pro, and thus the amount charged to the customer, did not include the $5. HELP!

 

 

Hi,

 

I was having a similar problem, and needed it fixed fast, so i took matters into my own hands.... if you look at cart/includes/modules/payment/paypal.php you should see on about line 89:

 

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))) .

 

if you have a look, it seems to be taking the shipping amount off the total amount and then passing it to paypal. (- $order->info['shipping_cost']). I just deleted this part and it seems to work perfectly now.

The code may seem a little different because i have optimised it for australian paypal, but it should still work if this hasn't been done.

 

Warning: I am only an amature, so please backup before trying this.

Link to comment
Share on other sites

I have my admin set to add a handling fee of $5. I received my first order since, and the order info on OSC shows the handling fee, and an order total that includes the handling fee. The order amount passed to Paypal Pro, and thus the amount charged to the customer, did not include the $5. HELP!

Usually you set the handling fee in the shipping modules.

Link to comment
Share on other sites

Hi,

 

I was having a similar problem, and needed it fixed fast, so i took matters into my own hands.... if you look at cart/includes/modules/payment/paypal.php you should see on about line 89:

 

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))) .

 

if you have a look, it seems to be taking the shipping amount off the total amount and then passing it to paypal. (- $order->info['shipping_cost']). I just deleted this part and it seems to work perfectly now.

The code may seem a little different because i have optimised it for australian paypal, but it should still work if this hasn't been done.

 

Warning: I am only an amature, so please backup before trying this.

It would depend on what PayPal contrib you have installed. If your solution works, that is good. I don't know of any optimisation for Australian PayPal (apart from to specify AUD and paypal.com.au). I am still using the US one while specifying AUD as a currency.

Link to comment
Share on other sites

It would depend on what PayPal contrib you have installed. If your solution works, that is good. I don't know of any optimisation for Australian PayPal (apart from to specify AUD and paypal.com.au). I am still using the US one while specifying AUD as a currency.

 

OK. I had set the handlng fee under Order Total. So I've gone in and set that to false, and set a handling fee in within the shipping vendors.

 

The line you pointed out is curious in that the shipping and handling were both included in the OS order and total, but the HANDLING was not passed to paypal, the shipping WAS.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...