HOME

Wordpress Paypal Integration

Ever want to intergrate Paypal payments into your blog to sell a product or service? Well, there is always someone out there who has the code but how exactly do you install it and make it work? Let me try to walk you through the steps.

Ken Villines offered code for Paypal integration in the Wordpress forums and got lots of, “I don’t understand or I can’t get it working, help!” which is a shame, his easy payment solution really works.

Note: Do not be insulted if you already know basic things like how to FTP, you might be surprised, many do not. This post is for those who need a little help getting payments working in Wordpress so let’s get started.

What you need:

  • An FTP Client - I like WS_FTP, need to learn how to use an FTP Client go here.
  • A Paypal account.
  • The Code to cut and paste into quicktags.js.
  • Instruction:

    1. Backup and save a copy of quicktags.js located in path: wp-includes/js/quicktags.js
    2. Here is the code you will need to cut and paste into quicktags.js, remove everything in your existing one (did you save a copy? good!) now replace it.

    3. Important: In your Wordpress console go to tab: options/writing and uncheck “Formatting: Users should use the visual rich editor by default” as you see in the picture below if you put on you glasses, hehe.
    4. Cut and paste this code into you quicktag.js file, save and upload it with your FTP client.

    Usage:

    Example Button:

    Add Item To CartLet me know if you have any issues, enjoy!

    Posted by admin 19.Jun.06

    You can follow any responses to this entry through the RSS 2.0 feed.
    You can leave a response, or trackback from your own site.

    46 Responses to “Wordpress Paypal Integration”

    1. Woody Says:

      Doesn’t work. I did exactly what yo said … no go.

    2. Fred Grisolm Says:

      I tried and it doesn’t seem to work for me either.

      Is there maybe a step missing?

    3. Fred Grisolm Says:

      Ah, you also need to turn off the MYSIWYG editor in order for it to work.

      Everything is good now!

      Thanks,
      Fred

    4. Jay Says:

      Same here. Copied pasted and even checked the quicktags.js. The new code is in their and no go.

    5. Jay Says:

      oh and my visual editor is on.

    6. Admin Says:

      What version or wordpress are you guys using? I just tried it on my other blog that is v2.0 and it is also working fine, strange.

    7. Jay Says:

      v.2.0

    8. Admin Says:

      I find that it is 99% of the time the webmaster, that’s you and me, there must be something you are missing.

      Play around with it, that’s how I figure these things that don’t exactly always work out.

      Have you asked the guy who wrote the script?

      Have you read all his “help” files?

      Have you followed his install instruction?

      I would love to login to your account and check it out but you might not want to give out you password.

    9. Jay Says:

      Might seem like a dumb question but where is the “MYSIWYG editor” ?

    10. admin Says:

      As I said above: options/writing and uncheck “Formatting: Users should use the visual rich editor by default” as you see in the picture.

      If it is unchecked you will not see the editor.

    11. Morten Says:

      Hi

      Im about to setup my blog whit PayPal I want to sell some digital products that are for download do you think this solution you have here will work for that as well?

      Reinholdt
      ———

    12. Ken Villines Says:

      Hi Aaron,

      Thanks for posting this! This is alot better then my explanation on the WP support forum. I am going to link back to this.

      cheers
      -Ken Villines

    13. admin Says:

      Thanks Ken!

    14. Mr. T Says:

      I could not get this to work.

    15. Fund My Stuff Says:

      This worked at first, now when the paypal button is clicked on it redirects to my blogs home page. I have no clue what happened.

    16. Eoin Dubsky Says:

      Nice plugin!
      I made a paypal plugin for Wordpress a few years ago and republished it on my blog last week:
      http://eoin.free.fr/blog/index.php/2006-09-02-my-old-wordpress-plugins-paypal-buttons-and-proximity-search

      It doesn’t work exactly the same way, but it’s the same idea.

    17. admin Says:

      Thanks Eoin, maybe people will have more luck with yours…

    18. admin Says:

      OK guys, had a few free minutes and found your issue, you are required one more step, go to your console in wordress, click the tab “Users” and look all the way down to the bottom (left) - ready for the good stuff?

      Uncheck “Use the rich visual editor when writing” the click the “Update Profile” button.

      Now do a new post and look for the Paypal button, it will magically appear allowing you to go forth and propser in whatever you do. :)

      Please link to my site or something from your blog, I do not get paid or any credit for helping people out and it really pisses my wife off BIGTIME! ;)

    19. stine Says:

      How about adding some of the option fields, like in PayPal’s button factory? I.E., “Size: Medium”

    20. Marc Abel Says:

      First, the tag works great! I doubt I’ll use it too many times, as it’s quicker to cut and paste, but one working example saves a lot of work.

      Second, I recommend you integrate #18 (the user-level editor option) into your instructions at the /top/ of the page.

    21. Marc Abel Says:

      Make that /almost/ great. On Mozilla 1.7.8 (haven’t tried the other suspects), this “add to cart” feature opens a new window with every click of the button. Other e-commerce sites don’t show multiple (and sometimes obsolete) copies of the cart.

    22. Richard Says:

      Since this write-up is basic and intended for people who ‘need a little help’, this may not apply…

      But for those who may have edited their quicktags.js file already, be aware that your custom additions and changes will be lost after following these steps.

      Not to worry though, you can easily bring them back in with a little patience and some copying & pasting from the backup copy you made.

      Many thanks to Aaron and Ken for your work.

    23. andrea Says:

      Hi, I linked to this page from my tutorial on setting WordPress up as an online shop. Thought you might like to know.

    24. admin Says:

      Thanks andrea!

    25. Robert Morgen Says:

      Looks like it’s working now. There may have been some sort of lag time with the V-Deck interface (http://www.vdeck.com/) that came with my hosting service.

      Either way, the magic button shows up in my editor in the menu bar and it seems to work great.

      A note here to users - You don’t have to go through the menu each time. You can just cut and paste the code into Notepad and then update the ‘name’,'item number’ and ‘price’ for each item and then paste it back where you need it.

      This also allows me to take the entire catalog page and add in the codes to distinguish which of my sales people are selling which items and easily replicate my pages!

      Thanks Aaron for getting us a good solution! :)

      Robert Morgen
      Mystic Wolf Press, Inc.
      http://www.mysticwolfpress.com

    26. Jeffnor Says:

      Everyone,

      If you are having troubles and all ready turned off the WYSISYG editor under Options -> writing, you also need to go to users, and at the bottome of your user profiles you should see this :
      Personal Options

      Use the visual rich editor when writing
      (UNCHECK that option as well)

      viola!
      I tested with PP 2.0.4 Cheers!!

    27. Andrey Says:

      SOLUTION

      So, I followed the instructions (BTW, another way to state them is “make a backup of your quicktags.js and replace it with this file” - I actually know some people who can make a mistake in a Copy-Paste operation). No result.

      Checked file permissions -all Ok.

      And then it hit me - RELOAD the bloody page! Firefox caches things, so the “Write Post” page was comming with the old quicktags.js.

      In Firefox to reload thoroughly, hold Ctrl button as you click on the “Reload” icon.

      That’s it!

    28. Mike Says:

      Works well but say you want the button positioned in the side bar and not the main body?

    29. Will Dayble Says:

      Remember to change mentions of ‘USD’ to ‘AUD’ or ‘GBP’ or whatever if you’re using a different currency! :)

    30. mitch Says:

      ok this worked for me on the first try and it is much better than trying to integrate the paypal form itself which always seems to fail. HOWEVER why does it pop up a new page (a duplicate page from the one clicked from) and the paypal window?

    31. Paula Says:

      This isn’t working for me either :(

    32. Paula Says:

      It says:

      We were unable to encrypt the certificate ID.

      Still not working.

    33. Peter Says:

      Worked like a charm! :) Thanks!

    34. ujjwal Says:

      lovely .. beautiful. just what I needed. :-)

    35. Lori Says:

      I had the ‘unable to encrypt certificate’ error problem with the raw paypal code and fixed it by moving the final “> at the end of the encryption code to be part of the long line above, rather than on its own line. That solved the problem. I have no idea if that is what caused the problem with the plugin, but it could be worth a try.

    36. Gemma Says:

      I’m using WP version 2.2.1 and there is no option anywhere to turn off the WYSIWYG editor so how am I supposed to get around that? I tried writing a new post but there is no new WYSIWYG or any PayPal additions to it. So this plugin doesn’t work for this version.

    37. admin Says:

      Gemma - I am using the latest version of wordpress and you can skip that step, just copy the quicktags.js file over and that’s it, done! :)

    38. adrian Says:

      Thanks for this. It works beautifully for me.

      Adrian

    39. A Giant Turtle Says:

      Does this work with Wordpress 2.31? I see no Paypal button as you have described when I go to create a new post or page after I have uploaded the new quicktags.js

      Where would this Paypal button appear? I assumed it would be with the other buttons, b i link b-quote, etc.

      Am I looking in the wrong place?

    40. Shawn Honnick Says:

      Is this meant to go along with some kind of plugin or does changing the quicktags.js somehow add this Paypal intergration functionality? If there is a plugin, where can I download that?

      Thanks!

    41. shawn Says:

      I have the plugin working fine. My problem is, I want to have this page always be the start page. When using the paypal shopping cart, it always redirects to the start page instead of where they made the order from. Is there a way around this? Like if http referrer = paypal, do not redirect to main page?

      Test blog here:
      http://www.oldradiofun.com/main/?p=5

    42. Manon Says:

      Well, it does work, but only for the Posts and not for Pages. Is there a way for this to work on Pages as well? BTW, I’m using Wordpress 2.3.1.

    43. Manon Says:

      Forget it! I had to log out and log in again. Now it’s showing up on pages! Thanks!

    44. Curandero Says:

      Is this compatible with Wordpress 2.5? If not, is there an update coming up soon?

    45. elvirs Says:

      looks like the option of visual editor is gone in wp2.5 :(
      any ideas how do handle this in version 2.5
      thanks?

    46. admin Says:

      Curandero - I am using the version 2.5 on other blogs and it is working fine, in fact, let me upgrade this blog with the wordpress automitic upgrade plugin to the latest and you will see, it also works here.

    Leave a Reply