<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>init.rb</filename>
    </added>
    <added>
      <filename>install.rb</filename>
    </added>
    <added>
      <filename>lib/captcha_helper.rb</filename>
    </added>
    <added>
      <filename>lib/captcha_image_generator.rb</filename>
    </added>
    <added>
      <filename>lib/captcha_util.rb</filename>
    </added>
    <added>
      <filename>tasks/generate.rake</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -0,0 +1,92 @@
+= Captcha
+
+This captcha generator is based on the very fine work of Eric Methot 
+(http://blogs.ericmethot.com/) all credit and thanks should go to him.
+
+This fork contains some cleanup of the code, and provides a better decoupling
+from RMagick
+
+Using Captcha is a five step process
+
+  1. Install RMagick
+  2. Install the plugin 
+  3. Generate a bunch of images off-line
+  4. Use the helper method(s)
+  5. Validate user input
+
+The plugin has been tested on OS X 10.5 using ImageMagick @6.4.1-8_0+q16 (via MacPorts) and
+the rmagick 2.5.2 gem.
+
+
+== Install the RMagic
+
+Follow the instructions on their site: 
+http://rmagick.rubyforge.org/install-faq.html
+
+
+== Install the Plugin
+
+Installing the plugin is as simple as issuing this command from the
+root of your rails application directory:
+
+  git clone git@github.com:zendesk/captcha.git
+
+
+== Generate a bunch of images off-line
+
+The reason why you don't need to generate images on the fly is that
+they have been generated in advance and all you do is pick one at 
+random. 
+
+First, define a salt for your application, do this by setting the global variable 
+CAPTCHA_SALT to a random string in e.g. your environment.rb
+  
+   CAPTCHA_SALT = 'Something really random here'
+
+Next, generate the images by running the following rake task, this takes a while:
+
+   rake captcha:generate COUNT=250
+
+This will create the '/public/images/captcha' directory if it doesn't
+already exist and put 250 randomly generated captcha gifs. 
+
+You can specify the following parameters when running the rake task:
+
+COUNT          - the number of images to generate, default 3
+IMAGE_HEIGHT   - the height of the captcha image in pixels, default 50
+IMAGE_WIDTH    - the width of the captcha image in pixels, default 260
+CAPTCHA_LENGTH - the number of characters in the captcha, default 5
+
+
+== Use the helper methods
+
+In your forms all you need to do is:
+
+  &lt;%= captcha_block %&gt;
+
+And add a little bit of CSS styling to get a nice looking captcha validation text field 
+and image. If you don't like the way it's setup then use the other helper methods 
+(see captcha_helper.rb), which are more granular.
+
+
+== Validate user input
+
+In your controller, you will need to do the following:
+
+PostController &lt; ApplicationController
+
+   helper CaptchaHelper
+
+   def create
+      ...
+      if captcha_validated?
+         ...
+      else
+         ...
+      end
+   end
+end
+
+That's it.
+
+Copyright (c) 2008 Zendesk, released under the MIT license</diff>
      <filename>README</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>d47ee5f41fe0269405d40f47a4a6c234f770a733</id>
    </parent>
  </parents>
  <author>
    <name>Morten Primdahl</name>
    <email>git@zendesk.com</email>
  </author>
  <url>http://github.com/zendesk/captcha/commit/df4b8243687ed439d9e0ad936bd43bce4436a576</url>
  <id>df4b8243687ed439d9e0ad936bd43bce4436a576</id>
  <committed-date>2008-07-16T09:14:14-07:00</committed-date>
  <authored-date>2008-07-16T09:14:14-07:00</authored-date>
  <message>initial import</message>
  <tree>17f0982eb44758f95deb2e3ecd74a9caf3ff4848</tree>
  <committer>
    <name>Morten Primdahl</name>
    <email>git@zendesk.com</email>
  </committer>
</commit>
