Forums / PayPal Express Checkout support / Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Locked

Started by tj1 on 6 Apr 2008, 2:27 AM · Views: 8,478

Results 1 to 20 of 28
This thread is locked. New replies are disabled.
6 Apr 2008, 2:27 AM
#1
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Would someone please tell me how to capture funds from within ZC 1.3.8 for paypal express transactions?

Is this even possible?

On ZC 1.3.7 you get the interface to do captures, among other options, by simply adding '&authcapt=on' to the url.

I think ZC 1.3.8 was supposed to have this enabled by default, but I don't see the interface, even if I append to the url like in ZC 1.3.7.

Here's a screenshot of what I get in 1.3.7 and 1.3.8: http://img.photobucket.com/albums/v58/acx101/zc_pp_express.gif

This is a very important and handy feature to me. Please let me know if this is not available in 1.3.8 so I can install 1.3.7 instead.

Thanks.

9 Apr 2008, 12:33 AM
#2
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

I don't know much about this, but it seems to me that this functionality was removed from the paypal express module in ZC 1.3.8.

When I use the developers tool kit in ZC 1.3.7 and ZC 1.3.8 to look for 'authcapt', I get this for ZC 1.3.7 in the file includes/modules/payment/paypal/paypalwpp_admin_notification.php

Line #383 : if (method_exists($this, '_doVoid') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputVoid; 

Line #384 : if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt; 

Line #388 : if ($response['TRANSACTION_TYPE'] == 'Authorization' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on')) {

On ZC 1.3.8, I see this:

Line #385 : if (method_exists($this, '_doVoid') && (MODULE_PAYMENT_PAYPALDP_TRANSACTION_MODE == 'Auth Only' || MODULE_PAYMENT_PAYFLOW_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputVoid; 

Line #386 : if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALDP_TRANSACTION_MODE == 'Auth Only' || MODULE_PAYMENT_PAYFLOW_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt; 

Line #390 : if ($response['TRANSACTION_TYPE'] == 'Authorization' || ($response['TRANSACTIONTYPE'] == 'cart' && $response['PAYMENTTYPE'] == 'instant' && $response['PENDINGREASON'] == 'authorization') || (isset($_GET['authcapt']) && $_GET['authcapt']=='on')) {

Please someone confirm this, I don't want to keep using ZC 1.3.8 if this is not supported.

2 May 2008, 6:07 PM
#3
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Sorry to bring this up again.

I really need to know the answer to this.

I've been running the new store and i haven't done any marketing at all because I don't want to a lot of orders while I have this issue.
I've only been getting a few orders so this hasn't been much of an issue.
Once I do some marketing I will be getting many orders and I don't want to have to go to paypal every time I need to do a capture or some other action.

No need to provide any details if you don't want, a simple yes or no answer will do.

Can I do a funds capture from within Zen Cart 1.3.8a using paypal express?

6 May 2008, 6:46 AM
#4
drbyte avatar

drbyte

Sensei

Join Date:
Jan 2004
Posts:
63,515
Plugin Contributions:
176

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

tj1:

Can I do a funds capture from within Zen Cart 1.3.8a using paypal express?

With a fresh install of v1.3.8a, I just did a successful auth-only express-checkout transaction, then went into my admin area, opened the order, where I see options for refund, capture, void, and did a successful capture.

The Express Checkout module has "Auth Only" selected for the Payment Action setting.

.
Zen Cart - putting the dream of business ownership within reach of anyone!
Donate to: DrByte directly or to the Zen Cart team as a whole

Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

22 May 2008, 5:19 AM
#5
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Hi DrByte, could you confirm whether that was a paypal express transaction.

I have fresh installation of 1.3.8a and I don't get this.

I don't know much about this, but I've reviewed the code in the paypalwpp_admin_notification.php file and there's reference of authcapt and the the paypal express module. I only see this for the Payflow module.

Could also some other users confirm wheter you get the interface to do funds captures in ZC 1.3.8a?

Thanks.

22 May 2008, 5:36 AM
#6
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

I just noticed this other thread http://www.zen-cart.com/forum/showthread.php?t=82033, which I guess is sort of similar and related.

Taking a quick look at the paypalwpp_admin_notification.php file (which I only understand very little) I think I see the code to produce the interface is there. However, it's missing the trigger to display this for the PayPal Express module.

22 May 2008, 7:03 AM
#7
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

...after playing with this for a while, I found that if I insert this line:

if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt;

almost at the bottom of the file, right after

  } else {  // PayPal 

This will show the capture box. I'm not sure if this works yet, I'll have to wait 'til I get an order to test. I'm not sure either if by doing this I'm breaking any code either.

28 May 2008, 5:07 AM
#8
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

For anyone interested, I just want to confirm that the edit I mentioned above works.

I'm still not sure if I'm the only one with this issue or if this is in fact missing from ZC 1.3.8

For those of you coming from the other thread about 'No Refunds', please try this, just like in the previous code, edit the file paypalwpp_admin_notification.php

Almost at the bottom of the file right after

} else {  // PayPal

insert this:

if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt;
if (method_exists($this, '_doRefund')) $output .= $outputRefund;

This should give you the capture and refunds boxes.

Please report if it works.

28 May 2008, 6:16 PM
#9
stflats avatar

stflats

New Zenner

Join Date:
Apr 2007
Posts:
81
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

tj1:

For anyone interested, I just want to confirm that the edit I mentioned above works.

I'm still not sure if I'm the only one with this issue or if this is in fact missing from ZC 1.3.8

For those of you coming from the other thread about 'No Refunds', please try this, just like in the previous code, edit the file paypalwpp_admin_notification.php

Almost at the bottom of the file right after

} else { // PayPal

> ```php
if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt;
if (method_exists($this, '_doRefund')) $output .= $outputRefund;
```This should give you the capture and refunds boxes.
> 
> Please report if it works.

I just came over from the "No Refund" thread and I'm sorry but I have no idea what this thread is about.  I don't know what the "Capture Funds" function is or what it is for and I don't know how it relates to the missing 'refund' function.  Thank you for trying to help but this has made me even more confused than I was earlier.  I just don't get it.  I am using v1.3.8a and am also using Paypal Express Checkout and it is set to "final sale." Thanks
28 May 2008, 6:41 PM
#10
tj1 avatar

tj1

Totally Zenned

Join Date:
Mar 2005
Location:
California
Posts:
628
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Adding the code you just quoted to the paypalwpp_admin_notification.php as indicated should make the refunds box appear.

28 May 2008, 10:04 PM
#11
stflats avatar

stflats

New Zenner

Join Date:
Apr 2007
Posts:
81
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Hi,

Okay, I found the php file and the area you mentioned and this is what's there:

  } else {
      if (method_exists($this, '_doRefund') && ($response['PAYMENTTYPE'] != 'instant' || $module == 'paypaldp')) $output .= $outputRefund;
      if (method_exists($this, '_doVoid') && $response['PAYMENTTYPE'] == 'instant' && $response['PAYMENTSTATUS'] != 'Voided' && $module != 'paypaldp') $output .= $outputVoid;
    }
  }
  $output .= $outputEndBlock;
  $output .= $outputEndBlock;
  $output .= '<!-- EOF: pp admin transaction processing tools -->';

So if I insert your code, is this what you are saying I should do:

} else {
      if (method_exists($this, '_doRefund') && ($response['PAYMENTTYPE'] != 'instant' || $module == 'paypaldp')) $output .= $outputRefund;
      if (method_exists($this, '_doVoid') && $response['PAYMENTTYPE'] == 'instant' && $response['PAYMENTSTATUS'] != 'Voided' && $module != 'paypaldp') $output .= $outputVoid;
      if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt;
      if (method_exists($this, '_doRefund')) $output .= $outputRefund;    
    }
  }
  $output .= $outputEndBlock;
  $output .= $outputEndBlock;
  $output .= '<!-- EOF: pp admin transaction processing tools -->';

?>

Thank you for getting back so quickly. I appreciate it.

29 May 2008, 7:56 AM
#12
cellmonsters avatar

cellmonsters

New Zenner

Join Date:
Dec 2007
Posts:
18
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

TJ1....................

YOU ARE THE MANNNNNNNNNNNNNNNNNNNNN.

So i did just as you said and Voila. I tested Express checkout and i had both the void or refund option. I did the refund and everything worked out lovely.

Thank you for the great help in resolving this.

Everyone.. This seems to solve the issue of "no refund". I personally tested this out with 2 test orders of 60 dollars and it just worked its charmes.

5 Jun 2008, 1:49 AM
#13
stflats avatar

stflats

New Zenner

Join Date:
Apr 2007
Posts:
81
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Thank you Tj1... That did it. I added the two lines directly under the line you stated, logged in to my admin area, looked at the order and there was the box with the "do refund" & "do partial refund" options. The "void order" function remained in tact as well.

Thanks again

8 Nov 2008, 11:41 PM
#14
coffee_granules avatar

coffee_granules

New Zenner

Join Date:
Nov 2008
Posts:
45
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Nice one, TJ1! - It now looks like refunds are go from admin console!

What do you mean it wouldn't work, so you removed all those annoying PHP tags....?!

1 Dec 2008, 1:14 PM
#15
munchie75 avatar

munchie75

New Zenner

Join Date:
Nov 2008
Posts:
12
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

I've been working through this thread and the other one 82033, and found the information very helpful.

However i'm not making any progress with getting the Refund functionality to show up.

Being a New zenner, i've been delighted to get this far with just reading existing posts, (you are a very helpful and informative bunch :-) )

However, i am using Paypal IPN and i am not sure if this work around only works for Paypal Pro / Express ?? (which i don't have)

Would be great if someone can clarify this, and also suggest a way this may work for Paypal IPN.

Many thanks

10 Dec 2008, 11:47 AM
#16
whitt avatar

whitt

New Zenner

Join Date:
Aug 2008
Posts:
29
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

The code works great. Thanks guys

Will this be an overide or will it be lost changes if I ever update my version?

19 May 2009, 12:46 PM
#17
phil020782 avatar

phil020782

Zen Follower

Join Date:
Jul 2007
Posts:
158
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

This code worked great thanks.
However it put the refund box at the left side instead of the right side so to get around that problem I moved the code to just under

if (method_exists($this, '_doVoid') && $response['PAYMENTTYPE'] == 'instant' && $response['PAYMENTSTATUS'] != 'Voided' && $module != 'paypaldp') 
$output .= $outputVoid;

This moved the refund box to the right just next to the void box.

6 Jun 2009, 4:32 PM
#18
samcyh avatar

samcyh

New Zenner

Join Date:
Oct 2006
Posts:
13
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Hi.

Can anyone tell me how can I turn on the refund or do void function in order to allow me refund customers? I went to admin page -> customer -> order select the customer order -> edit and manually put &authcapt=on at the end of the URL but I still cannot see the Do Void options.
http://www.xxxxxxxxxx.com.au/admin/orders.php?page=1&oID=4&action=edit&authcapt=on

I am using Zencart v1.3.8a and with the following payment options turn on.

Credit Card - Offline Processing cc 0
The Zen Cart FREE CHARGE CARD freecharger 0 default
PayPal IPN - Website Payments Standard PayPal 0 Processing
PayPal Express Checkout (sandbox active) PayPal 0 Processing

Please HELP...
Thanks
From Australia

8 Jul 2009, 12:59 AM
#19
crunch avatar

crunch

Zen Follower

Join Date:
Mar 2009
Posts:
227
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Is this an official bug fix? I am having the same issue with Paypal Express in 1.3.8a. When opening the order in the admin, there are no options for refund or capture - only a Voiding Order Authorizations box.

I don't see this issue in any of the bug threads.

8 Jul 2009, 1:42 AM
#20
crunch avatar

crunch

Zen Follower

Join Date:
Mar 2009
Posts:
227
Plugin Contributions:
0

Re: Help, how do you capture funds from within ZC 1.3.8? (PayPal Express)

Just made the revisions that TJ1 posted on page 1, in addition to moving the new code down a few lines as Phil020782 suggested on page 2 so that the refund box shows up next to the void box.

Here is how it looks now with new code added in red in new location. I now have a Order Refunds box and it's formatted next to the Voiding Order Authorizations box. Thanks! Hope this sticks in future versions.

/includes/modules/payment/paypal/paypalwpp_admin_notification.php:

  } else {  // PayPal
    $output .= $outputPayPal;
    if ($response['TRANSACTION_TYPE'] == 'Authorization' || ($response['TRANSACTIONTYPE'] == 'cart' && $response['PAYMENTTYPE'] == 'instant' && $response['PENDINGREASON'] == 'authorization') || (isset($_GET['authcapt']) && $_GET['authcapt']=='on')) {
      $output .= $outputEndBlock;
      $output .= $outputEndBlock;
      $output .= $outputStartBlock;
      $output .= $outputStartBlock;
      if (method_exists($this, '_doRefund') && ($response['PAYMENTTYPE'] != 'instant' || $module == 'paypaldp')) $output .= $outputRefund;
      if (method_exists($this, '_doAuth') && MODULE_PAYMENT_PAYPALDP_TRANSACTION_MODE == 'Auth Only') $output .= $outputAuth;
      if (method_exists($this, '_doCapt') && MODULE_PAYMENT_PAYPALDP_TRANSACTION_MODE == 'Auth Only') $output .= $outputCapt;
      if (method_exists($this, '_doVoid')) $output .= $outputVoid;
    } else {
      if (method_exists($this, '_doRefund') && ($response['PAYMENTTYPE'] != 'instant' || $module == 'paypaldp')) $output .= $outputRefund;
      if (method_exists($this, '_doVoid') && $response['PAYMENTTYPE'] == 'instant' && $response['PAYMENTSTATUS'] != 'Voided' && $module != 'paypaldp') $output .= $outputVoid;
      if (method_exists($this, '_doCapt') && (MODULE_PAYMENT_PAYPALWPP_TRANSACTION_MODE == 'Auth Only' || (isset($_GET['authcapt']) && $_GET['authcapt']=='on'))) $output .= $outputCapt;
      if (method_exists($this, '_doRefund')) $output .= $outputRefund;
    }
  }