Oops accidentaly posted it earlier - 
 All, I wanted to know is with earlier version of web2py the same code does 
not give an error. But it gives me a message as I attached in my earlier 
mail. But now when I deployed my web2py application on production with 
latest version, I am being given a ticket. I was expecting the message 
instead. So I wanted to know if it there is an issue with web2py or some 
modifications need in my code. 

*Rahul*

On Monday, September 3, 2018 at 9:59:02 AM UTC+5:30, Rahul wrote:
>
> Hi Anthony,
>        Yes  - It is defined in db.py file as  
>
> from gluon.tools import Recaptcha
>
>
> and is utilized in my controller as -
> publickey = "key"
>     privatekey = "key"
>     crud.settings.create_captcha= Recaptcha(request, publickey, privatekey
> ) 
>     crud.settings.create_captcha.label = 'Recaptcha' 
>     #crud.settings.create_captcha.comment = 'Try get it right!'
>     
>     # The crud works for the form 
>     form = crud.create(db.reguser)   
>     form[0][-2][0].append(LABEL("Spam Check "))
>
>
> On Monday, September 3, 2018 at 7:30:34 AM UTC+5:30, Anthony wrote:
>>
>> Recaptcha must be imported somewhere for you to use it. Do you have an 
>> import somewhere in your code? We need more details.
>>
>> Anthony
>>
>> On Friday, August 31, 2018 at 8:48:49 AM UTC-4, Rahul wrote:
>>>
>>> Hi All,
>>>     There seems to be an issue with latest version of web2py 2.17.1. I 
>>> am getting an exception like below for my project . However the same seems 
>>> to be working fine in web2py 2.15.3 but it gives the message shown in 
>>> attached image. 
>>>
>>> <type 'exceptions.NameError'> global name 'Recaptcha' is not defined
>>>
>>>
>>> File "web2py/applications/artpic/controllers/default.py", line 1759, in 
>>> register
>>>     crud.settings.create_captcha= Recaptcha(request, publickey, 
>>> privatekey)
>>> NameError: global name 'Recaptcha' is not defined
>>>
>>> Any idea ? 
>>>
>>> Rahul
>>>
>>

-- 
Resources:
- http://web2py.com
- http://web2py.com/book (Documentation)
- http://github.com/web2py/web2py (Source code)
- https://code.google.com/p/web2py/issues/list (Report Issues)
--- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to web2py+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to