Line | |
---|
1 | from zope.interface import Interface |
---|
2 | from zope.schema.interfaces import IASCIILine |
---|
3 | |
---|
4 | class ICaptchaView(Interface): |
---|
5 | """ Captcha generating and verifying view that is wrapper around |
---|
6 | captcha generation scripts located in skins folder. |
---|
7 | |
---|
8 | Use the view from a page to generate an image tag ('image_tag' method) |
---|
9 | and to verify user input ('verify' method). |
---|
10 | """ |
---|
11 | |
---|
12 | def image_tag(): |
---|
13 | """Generate an image tag linking to a captcha""" |
---|
14 | |
---|
15 | def verify(input): |
---|
16 | """ Verify user input. |
---|
17 | """ |
---|
18 | |
---|
19 | class ICaptcha(IASCIILine): |
---|
20 | u"""A field for captcha validation""" |
---|
Note: See
TracBrowser
for help on using the repository browser.