Bin-Blog logoBin-Blog

Learn about the latest in Web Development – as soon as I do.

Creating a Paypal Donate Widget in WordPress – Without a Plugin

By • Jun 20th, 2009 • Category: Tutorials, WordPress

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="" method="post">
<input type="hidden" name="cmd" value="_xclick">
<input type="hidden" name="business" value="">
<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="" border="0" name="submit" alt="Make payments with PayPal - it's fast, free and secure!">

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…

4 Responses »

  1. Yes, the text widget is a a great tool. I found out that you can add a whole lot of Google Translate requests using the same.

  2. nicole says:

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

  3. Ajay says:

    I have always used the PayPal wizard itself for code.

  4. […] Creating a Paypal Donate Widget in WordPress – Without a Plugin […]

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>