Displaying 3 results from an estimated 3 matches for "verify_recaptcha".
2012 Feb 12
1
Rails devise with recaptcha
...39;m trying to use the recaptcha gem with devise 2.0.0 in rails 3.2.1.
Every time I try, I am able to display the captcha and input the 2
words it asks about. But in my controller (using code I found on
github for the recaptcha gem, and after I replaced render_with_context
with just plain render) verify_recaptcha always returns false and when
I look at flash[:recaptcha_error] it says "recaptcha-not-reachable".
The only thing I can see that might be a problem is that one of the
examples of configuring the config values for recaptcha showed a proxy
setting. I don''t generally use a proxy so...
2009 May 13
0
Recaptcha plugin problem
Hi all,
I am using radiant CMS and I am trying to create custom extension and
add recaptcha validation to it
but when I call
if not verify_recaptcha(:private_key => ''aaaaaaaaaaa'')
#add error
end
I get: undefined method `verify_recaptcha'' for #<Comment:0x4f4c460>
Bellow is the full code for my model class
class Comment < ActiveRecord::Base
validates_presence_of :title, :author, :comment, :messag...
2008 Jan 28
2
Could this controller test be made simpler?
..."should re-render new template" do
post "create" #with no submitted params
response.should render_template("accounts/new")
end
# Controller code
def create
@account = Account.new(params[:account])
@user = @account.users.build(params[:user])
if verify_recaptcha(@account) && @account.save
redirect_to admin_listings_url
else
render :action => "new"
end
end
--
Posted via http://www.ruby-forum.com/.