Share Coding

Tutorials, Problems, Stuffs …

Use Paypal as a payment gateway

1. Register as a business account on Paypal.

2. Make a Paypal payment HTML form.

<form method="post" name="paypal_form" action="https://www.paypal.com/cgi-bin/webscr"> 
    <input type="hidden" name="business" value="account@gmail.com" /> <!-- Registered business account -->
    <input type="hidden" name="cmd" value="_xclick" />
    <input type="hidden" name="return" value="http://server/return.php" /> <!-- Client will redirect into this URL after payment is done -->
    <input type="hidden" name="notify_url" value="http://server/success.php" > <!-- Paypal server will access to this URL when payment is done -->
	   
    <input type="hidden" name="rm" value="2" />
    <input type="hidden" name="currency_code" value="HKD" /> <!-- Currency -->
    <input type="hidden" name="lc" value="HK" /> <!-- Location -->
    <input type="hidden" name="bn" value="toolkit-php" />
    <input type="hidden" name="cbt" value="Continue" />
    
    <!-- Payment Page Information -->
    <input type="hidden" name="no_shipping" value="1" />
    <input type="hidden" name="no_note" value="1" />
    <input type="hidden" name="cn" value="Comments" />

    <!-- Product Information -->
    <input type="hidden" name="item_name" value="Produce 1" /> <!-- Product Name -->
    <input type="hidden" name="amount" value="100" /> <!-- Price of the product -->
    <input type="hidden" name="quantity" value="1" /> <!-- Quantity of the product -->
</form>
Advertisements

One response to “Use Paypal as a payment gateway

  1. sms marketing 2013/02/07 at 8:28 pm

    Location marketing is small but can be powerful. How to incorporate it into internal communications and marketing efforts is something I’m quite curious about since that area seems ripe for development and opportunity.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: