source: products/quintagroup.formlib.captcha/branches/captchas-refactoring/quintagroup/formlib/captcha/captcha.txt @ 2058

Last change on this file since 2058 was 2058, checked in by mylan, 14 years ago

#173: Move quintagroup.formlib.captcha.form content into the quintagroup.formlib.captcha, add zope.app.form as direct requirement

  • Property svn:eol-style set to native
File size: 636 bytes
Line 
1--------------------------
2Captchas in a formlib form
3--------------------------
4
5Using quintagroup.formlib.captcha in a formlib form is simple. Just add a
6Captcha field to your schema, and away you go:
7
8  >>> from zope.interface import Interface
9  >>> from quintagroup.formlib.captcha.form import Captcha
10  >>> class CaptchaSchema(Interface):
11  ...     captcha = Captcha(
12  ...         title=_(u'Type the code'),
13  ...         description=_(u'Type the code from the picture shown below.'))
14
15and formlib will take care of the rest. The widget associated with this field
16will render the captcha and verify the use input automatically.
17
Note: See TracBrowser for help on using the repository browser.