How To Use reCAPTCHA with PHP


reCAPTCHA is a free CAPTCHA service that protects your site against spam, malicious registrations and other forms of attacks where computers try to disguise themselves as a human; a CAPTCHA is a Completely Automated Public Turing test to tell Computers and Human Apart. reCAPTCHA comes in the form of a widget that you can easily add to your blog, forum, registration form, etc.

reCAPTCHA helps prevent automated abuse of your site (such as comment spam or bogus registrations) by using a CAPTCHA to ensure that only humans perform certain actions.

  • It’s Free! Yep, reCAPTCHA is free.
  • It’s Useful. Why waste the effort of your users? reCAPTCHA helps to digitize books.
  • It’s Accessible. reCAPTCHA has an audio test that allows blind people to freely navigate your site.
  • It’s Secure. Most other CAPTCHA implementations can be easily broken.
  • It’s Popular. Over 100,000 sites use reCAPTCHA, including household names like Facebook, Ticketmaster, and Craigslist.
  • It’s Easy. reCAPTCHA is a Web service. As such, adopting it is as simple as adding a few lines of code on your site. For many applications and programming languages such as WordPress and PHP we also have easy-to-install plugins available. We generate and check the distorted images, so you don’t need to run costly image generation programs.

The reCAPTCHA PHP Library provides a simple way to place a CAPTCHA on your PHP website, helping you stop bots from abusing it. The library wraps the reCAPTCHA API.

To use reCAPTCHA with PHP, you can download reCAPTCHA PHP library. You will only need one file from there (recaptchalib.php). The other files are examples, readme and legal stuff — they don’t affect functionality.

Click here to read full docs and code example.

Source: google code

Related posts:

About Sach

Sachin is a web application developer, technology blogger and web addict! He has over 6 years of web development experience and he writes tutorials primarily focused on LAMP, Ajax, Api's, jQuery etc. He is usability expert and he always likes to share his knowledge with people.

, , ,