view examples/tutorial/geddit/form.py @ 829:e1c6163c5077

Add caching in the serialization stage, which speeds up the serialization of markup that has a lot of repetitive elements.
author cmlenz
date Fri, 13 Mar 2009 18:46:01 +0000
parents 71d3edd302ae
children
line wrap: on
line source
from formencode import Schema, validators


class LinkForm(Schema):
    username = validators.UnicodeString(not_empty=True)
    url = validators.URL(not_empty=True, add_http=True, check_exists=False)
    title = validators.UnicodeString(not_empty=True)


class CommentForm(Schema):
    username = validators.UnicodeString(not_empty=True)
    content = validators.UnicodeString(not_empty=True)
Copyright (C) 2012-2017 Edgewall Software