Freelancer.com

Go Back   Warrior Forum - The #1 Internet Marketing Forum & Marketplace > Warrior Support Forums > Programming
Register Blogs Social Groups Advertise with usHelp Desk

Reply
LinkBack Thread Tools
Unread 16th February 2013, 07:40 AM   #1
Warrior Member
 
Join Date: 2008
Location: , , United Kingdom.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to code a PayPal button to send a payment to a third party?

I know that there is an API function to split a single 'Buy Now' button payment, but I do not want to use that method. I want to make two distinct payments for a downloadable software product with two separate PayPal buttons thus:
1) A 'Subscribe Now' button that pays me, the programmer, an initial amount followed by a monthly subscription to my PayPal account. (I already know the PayPal code to do this.)
2) A second 'Buy Now' button that pays the licensee, whoever that may be, to his PayPal account.

I know that I can ask the licensee to create his own PayPal button and give me its 'Hosted Button ID', which I can then use in my code, but this is too error-prone. I want to program the second 'Buy Now' button to send the payment directly to the licensee's PayPal account by using ONLY the licensee's PayPal account email address.

How do I code the second 'Buy Now' button to do this, please?
mixedherbs is offline   Reply With Quote
Unread 16th February 2013, 03:27 PM   #2
WP Dev & Design
War Room Member
 
David V's Avatar
 
Join Date: 2011
Location: USA
Posts: 713
Blog Entries: 4
Thanks: 89
Thanked 237 Times in 193 Posts
Default Re: How to code a PayPal button to send a payment to a third party?

You need a hidden field to specify the email address instead of a hosted ID.
Code:
<input type="hidden" name="business" value="your-email@address.com">
This would be a real basic button and not all the hidden fields are required.
Code:
<form action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_s-xclick">
<input type="hidden" name="item_name" value="The Item Name">
<input type="hidden" name="item_number" value="001">
<input type="hidden" name="amount" value="1.00">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="business" value="your-email@address.com">
<input type="image" src="https://www.paypalobjects.com/en_US/i/btn/btn_buynow_LG.gif" border="0" name="submit" alt="PayPal - The safer, easier way to pay online!">
<img alt="" border="0" src="https://www.paypalobjects.com/en_US/i/scr/pixel.gif" width="1" height="1">
</form>
And of course you can have your own fancy button by swapping the button field with this
Code:
<input type="image" src="http://thebuttonurl.com/thebutton.jpg" border="0" name="submit" alt="Your Alt Tage">
.....

PluginCreationBlueprint is Closed!! JVZoo POTD!
if (!question_exist ('are_you_for_hire'); echo '<"99% Probably Not">';

Last edited on 16th February 2013 at 03:36 PM. Reason: Add line
David V is offline   Reply With Quote
Unread 16th February 2013, 09:26 PM   #3
Grouchy Old Geezer
War Room Member
 
Kirk Ward's Avatar
 
Join Date: 2006
Location: Ellijay, GA, USA. (Talk about being in the woods!)
Posts: 1,438
Thanks: 281
Thanked 63 Times in 48 Posts
Default Re: How to code a PayPal button to send a payment to a third party?

Contact PayPal about their "Chained Payments."

I believe that will do what you want.

"We are not here to sell a parcel of boilers and vats, but the potentiality of growing rich beyond the dreams of avarice."

Dr. Samuel Johnson (Presiding at the sale of Thrales brewery, London, 1781)
Kirk Ward is offline   Reply With Quote
Unread 18th February 2013, 07:23 AM   #4
HyperActive Warrior
War Room Member
 
dwoods's Avatar
 
Join Date: 2012
Location: Ohio, USA
Posts: 139
Thanks: 8
Thanked 35 Times in 31 Posts
Default Re: How to code a PayPal button to send a payment to a third party?

David V's solution is exactly what l was going to recommend.

Need a way to drive traffic to your new site?
-- Check out HelpMyHits.com!
dwoods is offline   Reply With Quote
Unread 19th February 2013, 06:26 AM   #5
Warrior Member
 
Join Date: 2008
Location: , , United Kingdom.
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default Re: How to code a PayPal button to send a payment to a third party?

Yes. The "business" parameter is exactly what I need. So simple! Thank you all very much.
mixedherbs is offline   Reply With Quote
Reply

  Warrior Forum - The #1 Internet Marketing Forum & Marketplace > Warrior Support Forums > Programming

Bookmarks

Tags
button, code, payment, paypal, third party

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 Off
Pingbacks are Off
Refbacks are Off




All times are GMT -6. The time now is 11:33 PM.