This article will tell you how to sign up for PayPal and how to configure the settings for the payment form we talk about in the How to generate product keys after an order article. If you haven't read that article first, you should.
If you want to test the PayPal integration without using your real money then you will need to create a PayPal sandbox account.
Included in the LimeLM Web API Pack is a payment example for C#, VB.NET and PHP. To configure this payment form to accept PayPal as a form of payment you need to make a few configuration changes. First, open the PaymentSettings.php/.cs/.vb file and make the following configuration changes:
Set the "UsePayPal
" variable at the top of the file to "true
"
Set the "AppPrice
", "Currency
", and "CurrencySign
" variables.
Set the "LimeLM_ApiKey
" (get it on your settings page) and "LimeLM_VersionID
" variables.
Set the "CheckScript
", "BuyPage
", and "ThankYouPage
" variables to the publicly-accessible locations of the included pages.
Set the "PayPalEmail
" variable with the sandbox email you created earlier and set the "PayPalSandbox
" variable to "true
".
You can customize the PayPal payment screen with your own logo. The logo must be hosted on a secure site — that is, the link must start with https:// not http://. Also, the logo must be at most 150px wide and 50px tall. If you have a logo that meets those requirements then set the "YourLogo
" variable in the PaymentSettings.php/.cs/.vb file. This is an example showing what the wyDay logo looks like on the PayPal checkout page:
Now that you have everything configured you're ready to test your PayPal payment. Run through the complete payment process to see everything works how you expect it to work.
After you've finished testing your payment process you're ready to sign up for a real PayPal "Business account" and change the "PayPalEmail
" variable in PaymentSettings.php/.cs/.vb to the email you used to create this account and set the "PayPalSandbox
" variable to "false
".