55

Paypal Hosted Buy Buttons

DAP can process Paypal payments using Paypal IPN (Instant Payment Notification).  All you need to basically do is to enable IPN within your Paypal account and create your Buy button with a few extra parameters. It’s all explained below.

So here’s what you need to do to process orders through Paypal using IPN, and have your buyers automatically added to DAP on your site.

1. Enable IPN within your Paypal account.

Follow this post to enable IPN first, and then come back here to this post.

2. Create your “Buy Now” or “Subscribe” or “Add to Cart” button

  • Log in to your Paypal account.
  • Click on Profile => Profile and Settings => My selling tools => Paypal Buttons => Update

 

  • Click on the “Create New Button”

On the Create New Button Page:

Step 1: Choose a button type and enter your payment details

1:  Choose any one of the following button types based on the type of product you wish to sell.
* Shopping Cart (for multiple-item purchases)
* Buy Now (for one-time products)
* Subscriptions (for subscription-based recurring products)

2: After selecting the button type, enter item name and price.

  • “Item Name”
    Make sure the Paypal “Item NameEXACTLY matches the “Product Name” that you created within DAP. In fact, login as DAP admin, edit the product, copy the text from the “Product Name” field, then paste this into your Paypal “Item Name” field, so that there are no typos. If the product names don’t match, DAP will ignore any IPN posts coming in from Paypal, which means no account will be created for your new member.

Step 3: Customize advanced features (optional)

  • just add a custom variable to the button as follows:

Under “Step 3: Customize advanced features (optional)” tab, within the “Advanced Variables” text box, enter the following (change the text YourSite.com below to your domain name).

notify_url=http://YourSite.com/dap/dap-paypal.php

(change the text YourSite.com to your domain name).

Save the button.

4. Copy the HTML code for this button

5. Publish the code on your web site’s sales page

..or WP page or post.

That’s it!

So when someone subscribes to, or purchases your product using this button, Paypal will send an IPN notification to your web site to the above link. DAP will then verify the product and payment status, and then will automatically add give the buyer/subscriber access to that product.

If the email id used in this purchase is not already associated with an account on your site, then DAP automatically creates a new account, and sends the buyer an “activation” email that requires them to click on a link to confirm and activate their account.

But If this email id belongs to someone who already has an account in DAP (existing buyer, purchased a different product this time), then DAP doesn’t create a new account for this user. It simply gives the existing account access to this new product.

So when the user logs in, they will see that they now have access to TWO products, with each product and the available URL’s listed separately.

Note: If you’re going to be using Paypal to process payments, then you don’t need to set up the Email Processing info in your DAP Admin > Config > Payment Processing screen. You don’t need to set up the DAP Email Order cron job either.

Click Here to Leave a Comment Below 55 comments
Veena Prashanth - December 12, 2012

Dwayne, i have edited your comments.

Reply
Hans - March 14, 2013

Hi Veena,

I wonder, I have set everything up and when I test my paypal button, right after purchase, I am redirected to http://amsterdamvideoguide.com/dap/admin/ in stead of http://amsterdamvideoguide.com/thank-you/.

Now I sent them to my thank you page because I have a improvely.com tracking code on my thank you page so that I can measure the conversion rate with Improvely.com

So at setup/config, I have paste the /thank-you/ destination in the box after Post Login URL (Global) . But still, it redirects the customer (me) to http://amsterdamvideoguide.com/dap/admin/

Any suggestions about what goes wrong?

Reply
Veena Prashanth - March 23, 2013

Hi Hans,

1. Pls test the purchase in a browser where you are not already logged in to dap as an admin. If you are logged-in to dap as admin, then whenever dap tries to redirect to the login page, you will always end up on the admin dashboard page

2. Pls use a different NON-ADMIN email to test the purchase. If your paypal email id is the same as your dap admin email id, then the chances are that after purchase, dap will auto-login the user, but as your paypal email is setup as dap admin, you will end up on the dap admin dashboard after the auto-login. The best way to test in this case is to update your DAP admin email id to a different non-paypal email id.

Thanks,
Veena

Reply
nick - July 4, 2013

Hi
Has anybody ever had this problem, when adding a dap generated paypal button code to the page it breaks the theme, I am running Genesis, I tried another theme, still the same, on the default twenty twelve theme it works?

Not heard from Genesis of a fix yet,

I get this code in the address bar :-

data:text/html,

If i take all the breaks out of the code, the paypal button just shows up really big and distorted in the page, something to do with the input? in css maybe?

Reply
Veena Prashanth - July 8, 2013

Hi Nick,

>>Has anybody ever had this problem, when adding a dap generated paypal button code to the page it breaks the theme, I am running Genesis, I tried another theme, still the same, on the default twenty twelve theme it works? << Have not heard of this problem. You can generate 'payment link' instead of payment button from the dap button generation page. Thanks, Veena

Reply

Leave a Reply: