Module: NiceTextCaptcha::FormBuilderExtensions

Defined in:
lib/nice_text_captcha/form_builder_extensions.rb

Instance Method Summary collapse

Instance Method Details

#nice_text_captchaObject



5
6
7
8
9
# File 'lib/nice_text_captcha/form_builder_extensions.rb', line 5

def nice_text_captcha
  captcha = NiceTextCaptcha::Captcha.new
  @template.flash[:nice_text_captcha_responses] = captcha.encrypted_answers_for(@object_name)
  label :nice_text_captcha, captcha.question
end