Skip to content
 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

= IqCaptcha

Prerequisite package:

ubuntu 10.04, sudo apt-get install libmagickwand-dev
ubuntu 11.04, sudo apt-get install libmagick9-dev
ubuntu 12.04, sudo apt-get install graphicsmagick-libmagick-dev-compat
CentOS, yum install ImageMagick-devel
Mac, brew install imagemagick

Pre requisite gem rmagick

Installation:

  • Place captcha background image named(iq_captcha_background.png) in your project's public folder
  • in Gemfile, gem 'iq_captcha' or gem 'iq_captcha', :git => 'git@github.com:barek2k2/iq_captcha.git' and run bundle install
  • in routes.rb, mount IqCaptcha::Engine, :at => '/iq_captcha'
  • Now restart your server and browse for testing, for exaample, http://localhost:3000/iq_captcha, if the captcha comes then it is OK for the test
  • To use the captcha in your project's view
    
    <img src="/iq_captcha?t=<%= Time.now.to_i %>&pointsize=25&color_code=ffffff">
    <input type="text" name="iq_captcha_result" />
    
  • In controller,
    
     if Captcha::valid?(session,params)
       # You are human being
     else
       # You are not human
     end
     
  • You are Done
  • This project rocks and uses MIT-LICENSE.

About

MVC based IQ,Math Captcha Gem for Ruby On Rails Application

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages