Simple Html Paypal Integration Form | Sanwebcorner

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 https://sandbox.paypal.com/cgi-bin/webscr url to https://www.paypal.com/cgi-bin/webscr 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:

<html>
<head>
<title></title>
<style>
.sanform
{
   width: 400px;
    background-color: #FFC107;
    padding: 25px;
    margin: 0 auto;
}

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

input[type="submit"]
{
background-color: #82640a;
    border-color: #82640a;
    color: #fff;
}
</style>
</head>
<body>

<form action="https://sandbox.paypal.com/cgi-bin/webscr" method="post" class="sanform">
    <input type="hidden" name="cmd" value="_xclick">
    <input type="hidden" name="business" value="sanwebcorneronline@gmail.com">
    <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">sanwebcorner.com</option>
      <option value="Amazon S3 Tutorial">sanwebtutorial</option>
      <option value="Some Other Tutorial">others</option>
    </select>
    <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>
</div>
<br />
<div class="email_invoice_payment">   
   <strong> Email (requiered)</strong><br />
    <input value="" name="os1" required>
</div>

    <input type="hidden" name="return" value="http://www.sanwebcorner.com/">

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


Post a Comment

Labels

360 degree view product image 3d rotate 3d text 3step-form Accordion menu ajax All Browsers Animated Background Gradient animation audio controller auto complete Best accordion menu bootstrap Bootstrap form validation border bounce effect on hover Breadcrumb calculate age by dob calendar Captcha change image on mouse move color chooser countdown Counter on scroll create random number Css css animation css buttons css hover css3 customized upload Button Date picker delete data from table Different scroll speed donation form download zip email otp verification email verifier Embed eventlist Expanding Menu feedbck form flash news section close button full screen menu Google custom search Google Maps Google reCAPTCHA Google site search gradient heart animation hide menu Horizontal News ticker Hover Htm Html html dropdown html form html form validation html5 html5 form validation Iframe image hover increment decrement textbox value based on select box Javascript javascript validation Jquery jquery validation js Layered image effect on mouse hover lock & unlock page scroll marquee marquee with close button mobile number validation mobile otp login Multi-level-drop-down-menu multi-level-form multi-select-checkbox Multi-Step-form Multiple File Upload in PHP mysql News ticker on hover change text to image our team page password generator password strength checker paypal form paypal html form Photoshop PHP php mailer populate html selectbox Popup image on click the link pure css Question type form random number generate Random password Redirect page Based on the select box while submit the form responsive responsive menu responsive popup box Responsive Vertical Time line design rotate image selectbox based on select box simple coming soon page simple countdown based on end date simple typing effect slider sliding tab sms otp login statistic counter on scroll switch tag shape team member Time picker toggle toggle view transparent button underline animation up down slide validation vertical fixed sidebar Webtips whatsapp link website Whislist Youtube