Simple Html Paypal Integration Form

Now we will see how to create html donation form using paypal. This is very simple for that you need one paypal account then you can create a html form. But you need to pass the paypal required parameter values. Now we can see what all are the parameter requrired by paypal

1. item_name

2. item_number

3. amount

4. Shipping values

5. currency_code

6. CustomerName

7. CustomerEmail

You will give those values in the form, you can pass the some values in the hidden field also. In this example you can see the code some of the values i given in the hidden field. This is not only a donation form you can use it for your product also. Now this form is in sandbox mode if you want live mode change form action from url to This example have the demo you can check it out in the damo link and you can also download full code by clicking the download button below. I hope this example is very useful to you.

Html Paypal Form:

   width: 400px;
    background-color: #FFC107;
    padding: 25px;
    margin: 0 auto;

input, select{
width: 400px;
    height: 40px;

background-color: #82640a;
    border-color: #82640a;
    color: #fff;

<form action="" method="post" class="sanform">
    <input type="hidden" name="cmd" value="_xclick">
    <input type="hidden" name="business" value="">
    <strong>Donation / Contribution? </strong><br />
    <select name="item_name">
      <option value="Donation">Donation</option>
      <option value="Contribution">Contribution</option>
    </select><br />   <br />

    <strong>Which tutorial are you donating for?</strong><br /> 
    <select name="item_number">
      <option value="PayPal Form Tutorial"></option>
      <option value="Amazon S3 Tutorial">sanwebtutorial</option>
      <option value="Some Other Tutorial">others</option>
    <input type="hidden" name="amount" value="200" >
    <input type="hidden" name="no_shipping" value="0">
    <input type="hidden" name="no_note" value="1">
    <input type="hidden" name="currency_code" value="USD">
<input value="CustomerName" name="on0" type="hidden">
<input value="CustomerEmail" name="on1" type="hidden">
<br /><br />
<div class="first_name_invoice_payment">
    <strong>First/Last name (required)</strong> <br />
    <input value="" name="os0" required>
<br />
<div class="email_invoice_payment">   
   <strong> Email (requiered)</strong><br />
    <input value="" name="os1" required>

    <input type="hidden" name="return" value="">

    <br /><br />
    <input type="submit" value="Pay with PayPal!">

Post a Comment