Opened 19 years ago

Last modified 6 years ago

#73 enhancement closed fixed (fixed)

Forms in Woven are annoying

Reported by: radix Owned by:
Priority: low Milestone:
Component: Keywords: web
Cc: Glyph, radix, dp Branch:


Change History (6)

comment:1 Changed 19 years ago by radix

Currently, when you submit data through a Woven Form that
raises a FormError for one reason or another, another form
is generated for you in a plain white page.

It is preferable to have the error reported in-line with the
_original_ page that displayed the form. This is tricky, but
there are ways to do it. Here's one (so far sketchy) idea.

I propose a "FormPage" class that allows the programmer to
specify one or more Forms that will be used in a Page. All
of these forms, in the template, should have an "action"
that references the same FormPage. The MethodSignatures for
these forms will be associated with a callback (as usual)
and a Redirect (as idiomatically usual) that points to,
e.g., a results display page.

So, our FormPage is also the processor of all forms used in
that FormPage. If a FormError occurs any time during
processing, then the FormPage can rerender itself entirely,
putting an error message near the appropriate form that the
user put bad data into.


comment:2 Changed 19 years ago by Glyph

We need a FormPage thing, that's for sure, but the one you
suggest is impossible.  a URL for GET may specify multiple
forms to display, but a URL for POST must only specify one
form to submit.

The FormPage we need is a Resource that has *2* URLs for *1*
form.  That way you can bounce back and forth between
displaying errors on the "display" template without creating
confusion on the "post" URL

take a look in sandbox/glyph/formdemo for an implementation

comment:3 Changed 19 years ago by itamarst

Looks like dp is on to this.

comment:4 Changed 18 years ago by jknight

This bug is being resolved, wontfix, as woven is "almost deprecated" and unmaintained. Use nevow 
instead. See <> and the twisted-web mailing list <http://>.

comment:5 Changed 11 years ago by <automation>

Owner: dp deleted

comment:6 Changed 6 years ago by Ying Li <cyli@…>

In e56d76f:

Error: Processor CommitTicketReference failed
 does not appear to be a Git repository. See the log for more information.
Note: See TracTickets for help on using tickets.