Sha256: 1aa34573a497ede66ef693dac94dadb234d82ec06103e8df3d833b6556391556

Contents?: true

Size: 375 Bytes

Versions: 7

Compression:

Stored size: 375 Bytes

Contents

module EasyCaptcha
  # helper class for ActionView
  module ViewHelpers
    # generate an image_tag for captcha image
    def captcha_tag(*args)
      options = { :alt => 'captcha', :width => EasyCaptcha.image_width, :height => EasyCaptcha.image_height }
      options.merge! args.extract_options!
      image_tag(captcha_path(:i => Time.now.to_i), options)
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
easy_captcha-0.5.0 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.7 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.5 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.4 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.3 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.2 lib/easy_captcha/view_helpers.rb
easy_captcha-0.4.1 lib/easy_captcha/view_helpers.rb