Creating a Paypal Donate Widget in WordPress – Without a Plugin

WordPress Helo Effect

Paypal donate plugins. This is extremely simple to implement – you don’t even have to edit the code to get this done.

Widget Mode

Open the admin side of your blog and go to Appearance > Widgets. Now add a Text widget to the sidebar you want the widget in. Edit it and paste the HTML code from the Paypal site.

<form name="_xclick" action="https://www.paypal.com/cgi-bin/webscr" method="post">
<input type="hidden" name="cmd" value="_xclick">
<input type="hidden" name="business" value="binnyva@hotmail.com">
<input type="hidden" name="item_name" value="Donation">
<input type="hidden" name="currency_code" value="USD">
<input type="hidden" name="amount" value="25.00">
<input type="image" src="http://www.paypal.com/en_US/i/btn/btn_donate_LG.gif" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!">
</form>

Make sure you use your own paypal ID in the business field.

Save the widget – and you’re done.

Theme Mode

Another method is to add the same code to the theme’s code directly. Usually in the sidebar.php file. I kind of prefer this method – but it involves code editing, FTP, etc. Not everyone is comfortable with this.

Post Mode

Last but not the least, you can embed the code directly into a post. This is perhaps the simplest of all. Below is a working sample of the code…







About Binny V A 102 Articles
Freelance Web Developer on the LAMP Platform. Maintains a blogs http://blog.binnyva.com/. Other sites include Bin-Co and OpenJS

3 Comments

  1. Well I thought we have wizard inside paypal that help create HTML code for this button. Anyway, nice post ! Keep it up !

1 Trackback / Pingback

  1. Plugin Killer Series for WordPress: The End | Bin-Blog

Leave a Reply to Ajay Cancel reply

Your email address will not be published.


*