MicrostockGroup Sponsors


Poll

Is PayPal Working for you?

PayPal IS Working
7 (63.6%)
PayPal is NOT Working
4 (36.4%)

Total Members Voted: 7

Voting closed: April 11, 2013, 16:00

Author Topic: Setting up PayPal  (Read 15728 times)

0 Members and 2 Guests are viewing this topic.

« on: March 28, 2013, 02:42 »
0
I am attempting to test purchasing, but I am absolutely stumped by PayPal IPN... my test payments are going through but nothing is happening after that.  Can someone more technical maybe take a peek at the IPN file provided and give us an idea of what needs to be changed/added?  Also what page to put in our PayPal settings as the page it's supposed to be "listening" to? That'd be awesome :)

On another note...I have my PayPal (verified business account) set up to take payments from one of my other sites so all of that site's information is appearing on my checkout page.  I was wondering wear the logo we upload for PayPal comes in and if anyone knows of a good way to set up different branding depending on which site customers check out from?


Leo Blanchette

« Reply #1 on: March 28, 2013, 04:04 »
0
Welcome to IPN (Instant Payment Notification)! I was wondering when someone would ask about that.

Its easy.

Buyer goes to your cart.
Buyer Pushes "Get Licenses". Array of values are posted to Paypal.
...
Transaction succeeds or fails.
Paypal post back to your IPN listening script (the IPN link in your admin area) what happened.

Your site says "Does payment = cart value?"
If "Yes" Cart is transformed to user files.

User pushes download button and image is resized and delivered on command. (Images are not pre-sized so as to avoid excess space useage and file amounts)

So to answer your question -

Setting up Paypal IPN - Here are the verbal instructions, for lack of time. I will post some tutorials afterward.

Go to paypal-> profile-> selling options-> instant payment notifications (from memory, something like that).
Put in your paypal IPN listening script link from your admin. There are some other options there too.

While your at it, make the "return link" the customer page, so that paypal redirects the customer to their licensing area.

Thats it!


Leo Blanchette

« Reply #2 on: March 28, 2013, 04:06 »
0
One more thing - notice the sandbox or live paypal options link to either paypal or the paypal dev site. One is for "pretend" transactions, and simply toggle over to live to make it not pretend.

edit - while your at it set yourself up a customer account for testing. Paypal won't let you purchase from yourself. You can also experience the customer process and make sure it all works. You should get a detailed "Thank you for your purchase" email, and "thank you for signing up" email. Let me know if that doesn't happen.

Also as a bonus, customer purchase emails are cc'd to you. Its fun to see your phone's email go off saying "You've got a sale!"

Poncke

« Reply #3 on: March 28, 2013, 06:56 »
0
https://www.x.com/search/site/ipn

x.com is paypal developers website. Also, the sandbox is renewed, its now developer.paypal.com

« Reply #4 on: March 28, 2013, 14:54 »
0
I set up this quick PDF with a couple of screenshots of the PayPal site settings for anyone who wants a visual.  Very easy!  I did a real live sale and got the payment, both emails (one to the customer one CC to me) and was able to download the image as the customer with no problems.  The only missing link is the PayPal site redirecting the customer back to the page.  So two quick questions to clarify:

1) Where do we set the return URL - I don't think setting it up globally in my PayPal account will work because I have other sites that I use PayPal as a payment method.  Does someone more familiar with PayPal know how to customize this on a site by site basis?

2) Should we have to make any manual changes to the paypal_ipn.php or is it good to go with just the interface toggle from live to sandbox?

Poncke

« Reply #5 on: March 28, 2013, 16:28 »
0
Why does no one ever check x.com? Its the site that answers all questions PayPal

Leo Blanchette

« Reply #6 on: March 28, 2013, 16:39 »
0
I set up this quick PDF with a couple of screenshots of the PayPal site settings for anyone who wants a visual.  Very easy!  I did a real live sale and got the payment, both emails (one to the customer one CC to me) and was able to download the image as the customer with no problems.  The only missing link is the PayPal site redirecting the customer back to the page.  So two quick questions to clarify:

1) Where do we set the return URL - I don't think setting it up globally in my PayPal account will work because I have other sites that I use PayPal as a payment method.  Does someone more familiar with PayPal know how to customize this on a site by site basis?

2) Should we have to make any manual changes to the paypal_ipn.php or is it good to go with just the interface toggle from live to sandbox?

I'm glad to see you had a working paypal transaction! Glad to hear no bugs on this.

Return link - can be set up in the customer area to post. I'll monkey with it some more. I thought setting it up in paypal was sufficient.

You can make changes to IPN, but make sure they are meaningful and that you send them to me so I can include them with next release. Otherwise they will be over-written. Towards the end of the testing phase I'm going to be putting in ton of HOOK functions, which allows you to insert your own code via whatever plugins you write. If anyone wants to develop.

Leo Blanchette

« Reply #7 on: March 28, 2013, 16:40 »
+1
Why does no one ever check x.com? Its the site that answers all questions PayPal
That would be great. I tried to keep payment system as simple as possible so nothing breaks. Any questions in paypal should be asked over there for many reasons.

farbled

« Reply #8 on: March 31, 2013, 11:21 »
0
Hmm, I tried a (new) personal account to do a paypal checkout and I got an error that I suspect has more to do with paypal than the site. Has anyone seen this?



« Reply #9 on: March 31, 2013, 11:51 »
+2
Without know what information you missed out it is a little difficult to answer that one  :)

x.com - why don't I use it - well, never having heard of it prior to this thread it is a would have been a little difficult.  It is logical when looking for information about paypal to look on the paypal site not on something with a completely different name.   I also gave up on the sandbox - have used one before but it was much more straightforward then. 


I just used real paypal with tiny amounts of money to test site out (paypal worked, getting downloads did not so if anyone has done both I would love to know how you did it.)  I am using version 6

farbled

« Reply #10 on: March 31, 2013, 11:55 »
0
Partially figured out. It has to do with the new currencies in the newest theme. I backed up to the previous version and it works a-ok now. Now to figure out where the download link is after I purchase..... :)

Leo Blanchette

« Reply #11 on: March 31, 2013, 12:04 »
0
Test paypal out rigorously. We don't want bugs in that. Sunday was my last day for bug updates. First make sure there is def a problem and I will do one last fix tonight.

farbled

« Reply #12 on: March 31, 2013, 12:11 »
0
I tired in Chrome, Mozilla and ie and got the error. However when I restored to the previous version it went away. Not sure why, but it could be my own fault messing with things. Lastly, I don't know how to enable the image license link so that customers can download the purchased image. In the backend the license url disappears when I click save.

Leo Blanchette

« Reply #13 on: March 31, 2013, 12:15 »
0
Ok, please keep focusing bug reports on anything to do with paypal. That way when I get home tonight I can definitely get you running properly. It would appear this is the final little quirk (serious one anyway) so thanks.

You guinea pigs should be wearing graduation caps soon. WHich one of you gifted photographers/illustrators wants to make an pic of a guinea pig with a graduation cap? :D

Leo Blanchette

« Reply #14 on: March 31, 2013, 12:17 »
0
For tonight detour to bug stomping thread - http://www.microstockgroup.com/symbiostock-technical-support/symbiostock-test-build-the-bug-stomping-thread!/msg307483/?topicseen#new

Let this thread sink. After sunday MSG should have their forum back from the Symbiostock Guinea Pig Invasion. I've just coined that term. Think it will take?

Leo Blanchette

« Reply #15 on: March 31, 2013, 12:30 »
0
[snip] sorry wrong thread.

« Reply #16 on: March 31, 2013, 15:16 »
0
After a bit of a struggle I now have Paypal working in the sandbox and download is working.

For others still having problems, these are the things that tripped me up:

1. Leo's auto-generated IPN process address is not quite right if you're using the child theme.
I got http://photo.travelling-light.net/wp-content/themes/symbiostock-child/ipn/paypal_ipn.php and I think you need to get rid of the -child.

2. That address has to go into the profile of the virtual business account in the sandbox, not just your real one, and you get into that by logging into the front door of Paypal with your virtual username and password.

Having sorted that, when I returned to my site from Paypal, the shopping cart had changed and there was a download link under the thumbnail. I got my copy of the customer email. The actual customer email bounced because I had used a nonsense address for it.

Hope that helps somebody.

farbled

« Reply #17 on: March 31, 2013, 15:39 »
0
Thanks! I've changed it in Paypal but for some reason it won't let me change it in the Symbiostock settings. It changes back to -child when I hit save. I'll disable the child theme and see if that works.

-edit, no dice. I'll keep trying...
« Last Edit: March 31, 2013, 15:41 by farbled »

« Reply #18 on: March 31, 2013, 15:57 »
0
Thanks! I've changed it in Paypal but for some reason it won't let me change it in the Symbiostock settings. It changes back to -child when I hit save. I'll disable the child theme and see if that works.

-edit, no dice. I'll keep trying...

It doesn't matter what it says in the Symbiostock settings, it's just a FYI, generated automatically. As long as it's correct in Paypal you're in business.

farbled

« Reply #19 on: March 31, 2013, 16:23 »
0
Ok, I changed it in paypal, but still no download link or thank you email. Hmmm. I'm stumped.

Leo Blanchette

« Reply #20 on: March 31, 2013, 21:12 »
0
After a bit of a struggle I now have Paypal working in the sandbox and download is working.

For others still having problems, these are the things that tripped me up:

1. Leo's auto-generated IPN process address is not quite right if you're using the child theme.
I got http://photo.travelling-light.net/wp-content/themes/symbiostock-child/ipn/paypal_ipn.php and I think you need to get rid of the -child.

2. That address has to go into the profile of the virtual business account in the sandbox, not just your real one, and you get into that by logging into the front door of Paypal with your virtual username and password.

Having sorted that, when I returned to my site from Paypal, the shopping cart had changed and there was a download link under the thumbnail. I got my copy of the customer email. The actual customer email bounced because I had used a nonsense address for it.

Hope that helps somebody.


* * * YOU ROCK * * *
I would have NEVER solved that so quickly, because I had NO idea the child theme would do something like that. Why would the child theme do that?!?!?! I guess I have plenty to learn too. YES - I will fix that tonight.
« Last Edit: March 31, 2013, 21:15 by Leo »

Leo Blanchette

« Reply #21 on: March 31, 2013, 21:13 »
0
[whups please delete]

« Reply #22 on: April 01, 2013, 06:40 »
0
I was having trouble after upgrading to the latest version, with the sale going through, but not triggering once it got back to the customer area. I tracked it down to fixing the following:

In ipn/paypal_ipn.php line 34, it reads:

//sandbox url...uncomment for testing
$ch = curl_init('https://www.sandbox.paypal.com/cgi-bin/webscr');
//$ch = curl_init('https://www.paypal.com/cgi-bin/webscr');


it should be (for real sales, not when sandbox testing):

//sandbox url...uncomment for testing
//$ch = curl_init('https://www.sandbox.paypal.com/cgi-bin/webscr');
$ch = curl_init('https://www.paypal.com/cgi-bin/webscr');


Now it is working beautifully.

farbled

« Reply #23 on: April 01, 2013, 10:03 »
0
I was having trouble after upgrading to the latest version, with the sale going through, but not triggering once it got back to the customer area. I tracked it down to fixing the following:

In ipn/paypal_ipn.php line 34, it reads:

//sandbox url...uncomment for testing
$ch = curl_init('https://www.sandbox.paypal.com/cgi-bin/webscr');
//$ch = curl_init('https://www.paypal.com/cgi-bin/webscr');


it should be (for real sales, not when sandbox testing):

//sandbox url...uncomment for testing
//$ch = curl_init('https://www.sandbox.paypal.com/cgi-bin/webscr');
$ch = curl_init('https://www.paypal.com/cgi-bin/webscr');


Now it is working beautifully.

Sigh, looks like I'm the odd one out. I'm doing live sales testing and I still cannot get the download link to appear. The latest version still won't let me complete a sale so I'm 2 versions back which works fine except for the download link and thank you email. I made the change above, but no dice. I'm a little frustrated because it's the very last peice I need and then I can concentrate on uploading and maybe even selling some to real customers. :) Any other suggestions?

« Reply #24 on: April 01, 2013, 10:59 »
0
Try re-downloading and reinstalling in case something else got scrambled in transit ?   


 

Related Topics

  Subject / Started by Replies Last post
Setting up Veer

Started by click_click « 1 2 3  All » Veer

57 Replies
19752 Views
Last post August 09, 2009, 08:15
by bittersweet
4 Replies
10647 Views
Last post December 06, 2010, 09:39
by Sean Locke Photography
19 Replies
15077 Views
Last post November 12, 2012, 19:12
by Poncke
4 Replies
2465 Views
Last post April 06, 2013, 18:15
by Chico
9 Replies
4478 Views
Last post June 25, 2013, 11:26
by jshooz

Sponsors

Mega Bundle of 5,900+ Professional Lightroom Presets

Microstock Poll Results

Sponsors