Paypal subscription button - php

Background
I'm building a website where I need to use some sort of recurring billing payment method. My client does not have Paypal's Website Payments Pro so he decided to use a simple Subscribe button.
Problem
This is all nice and easy to use but how would I get a notification from Paypal when such a payment has been made? I had some experience with Paypal before and there was a field return_url that would be accessed by Paypal to notify the website but checking the variables on their site this field does not exist anymore or perhaps not available with this type of button.

when you create subscribe button that time you will find that option(in step 3) , so according your need you can set url and get ipn variable
Step 3: Customize advanced features (optional)
Take customers to this URL when they cancel their checkout
http://yourwebsite/complete_registration.php?action=cancel&sts=0
Take customers to this URL when they finish checkout
http://yourwebsite/complete_registration.php
Advanced variables
notify_url=http://yourwebsite/complete_registration.php
i hope it help you

Related

Can I sell subscriptions without subscription button using Pay Pal

I have website on which I want to sell subscriptions. Here is the scenario:
In the pricing tables there is button purchase. When user click on the button I am sending him to the form where he can enter his details (name, email, password) . When visitor click on the submit button his account is created and I want to redirect him to the pay-pal page, where the user can make the payment.
Can anyone point me to some article on pay-pal page where I can read instructions how can I do that, and which model/api/gateway/whatever I should use for that? I know how to create subscription buttons, but using them doesn't seem to fit in my scenario-flow. Please note that I need help to FIND information how this can be done, I will find my way with the coding.
PayPal supports multiple ways to sell subscriptions.
You can use one of these depending on type of complexity you can handle and features you want:
PayPal WPS Subscription Buttons
https://developer.paypal.com/docs/classic/paypal-payments-standard/integration-guide/Appx_websitestandard_htmlvariables/#recurring-payment-variables
This is a button integration, you can specify your subscription terms and PayPal will take care of making recurring payments. You can also maintain inventory, profile & loss tracking. This will require very less coding effort from your end.
API Integration: https://developer.paypal.com/docs/integration/direct/billing-plans-and-agreements/
This is an API integration: Here you need to create a Plan and redirect the buyer to paypal to get buyer's approval. Then you can do recurring payments via API calls. You will need to maintain a secure database of approval ids, buyer details and the agreement details. Also you will need a daemon which should call PayPal apis on subscription dates.
You can also refer to this guide to get more info on different flows supported by paypal: https://developer.paypal.com/docs/directory/

how do i link paypal account with online store using php

I am not sure what this is called but here is what i am looking to do.
I am trying to make a php script that will create a link between our store account and paypal buyer, so that when they click our buy button it will process the payment without any future confirmations or user actions.
I have tried the paypal sdks and integration wizard no luck, Does anyone know of a working example of what i am trying to do?
Billing agreement(also called Reference Transactions) allows customer to agree the payment once on your website or app, then you call an API with the billing agreement ID to tell PayPal to charge the customer. Please see document here . You will need to contact PayPal to enable you to use Billing agreement, it's not easy to get approval:(
Integrating Paypal buttons are pretty straightforward.
Go to your merchant account.
Go to your Create Paypal Button page.
Choose whatever the button types you want. Configure it with Price etc.
Now just copy and paste the code generated.
It just works.
P.S
There is an option in your merchant account page to set the returning address from Paypal. You can set a returning page and catch all the transaction details via HTTP Post method when it is called by Paypal.
There is this Sandbox account type in Paypal which you can do a lot of playing with.

How can I make an automatic PayPal buy button?

I want my PHP web application to have the ability to save the user's PayPal details in their user account.
When they go to purchase items, rather than going through the standard PayPal form, it will automatically grab the user's PayPal details from their user account, and make the payment directly from my website. There is definitely a way to do this, as I have seen this feature on sites such as Freelancer.com
Thanks for the help! :)
No, you don't need Payments Pro for that. That would only be if you want to do it with direct credit cards. What you're after in general is called Reference Transactions, and when done with PayPal Express Checkout it uses Billing Agreements.
You'll use Express Checkout and/or Payments Pro (optional) to process an original authorization or sale transaction. Then, you can send that ID you get back in that original transaction along with a new amount in the DoReferenceTransaction API and that new amount will be instantly processed without any redirection or further authorization required.

stripe payments without popup

I am trying to integrate Stripe on a Symfony2 project, and the only payment method I see on their documentation is the "Pay with card" button https://stripe.com/docs/checkout which creates an embedded popup on my project. But the problem is that I need the users to insert their credit card number on Stripe's website, just like Paypal does. Is there any payment method that Stripe provides, and get all the user's informations from a form that is on their website?
Thank you.
Stripe doesn't offer a redirection to its site to collect card details. (source)
In most instances, buyers don't even know they're using Stripe to pay.
To collect card details and turn them into a token, you can either:
use Checkout, a premade form with some customization options, or
make your own form using Stripe.js.
If neither of these is an option for you, you can check the list of Stripe third-party integrations to see if something fits your needs.
This is now possible.
Stripe customers are now able to use Client-only Checkout feature which is currently in beta. Flow is the same as with PayPal - users will be redirected to Stripe-hosted checkout website.
Directing customers to Stripe to make payments online

Paypal - Dynamically change HTML variable for "Buy Now" button?

I'm new to Paypal integration. I need to dynamically change the HTML variable to the Buy Now button since I need to calculate discount_rate and shipping.
At first I use the hosted button, but then realized that I can't add new variables.
So I found this alternative way which is creating our own button. But then the customer can simply "Inspect Element" and change the value of the input.
Is there better and more secure way to implement dynamic pricing for Paypal?
Can I submit the payment through backend script like PHP?
Thanks
You can use the PayPal express checkout API to create a purchase in the background then send the user to PayPal with a token linked to this purchase.
if you do go down this route, I recommend using this class as it is very simple, yet powerful;
https://github.com/thenbrent/paypal-digital-goods/
On the other hand you can continue what you are doing with the non-hosted buttons and simply check the gross amount paid by the user against what they should have paid in your notify script.

Categories