source:
trunk/examples/tutorial/geddit/form.py
| Last change on this file was 735, checked in by cmlenz, 16 years ago | |
|---|---|
|
|
| File size: 393 bytes | |
| Line | |
|---|---|
| 1 | from formencode import Schema, validators |
| 2 | |
| 3 | |
| 4 | class LinkForm(Schema): |
| 5 | username = validators.UnicodeString(not_empty=True) |
| 6 | url = validators.URL(not_empty=True, add_http=True, check_exists=False) |
| 7 | title = validators.UnicodeString(not_empty=True) |
| 8 | |
| 9 | |
| 10 | class CommentForm(Schema): |
| 11 | username = validators.UnicodeString(not_empty=True) |
| 12 | content = validators.UnicodeString(not_empty=True) |
Note: See TracBrowser
for help on using the repository browser.
