Re: Multiple validation error handling in clean()

2008-02-14 Thread robstar
That worked ! I like that solution much better too! Thanks for your help. Rob On Feb 14, 2:14 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Thu, 2008-02-14 at 10:54 -0800, robstar wrote: > > Thanks Malcolm, I'll try it out. > > > Some of this feels kind of hack'ey what's the co

Re: Multiple validation error handling in clean()

2008-02-14 Thread Malcolm Tredinnick
On Thu, 2008-02-14 at 10:54 -0800, robstar wrote: > Thanks Malcolm, I'll try it out. > > Some of this feels kind of hack'ey what's the correct, clean way > to do this kind of processing with newforms?? Putting an error against two fields simultaneously isn't a very normal practice. You're

Re: Multiple validation error handling in clean()

2008-02-14 Thread robstar
Thanks Malcolm, I'll try it out. Some of this feels kind of hack'ey what's the correct, clean way to do this kind of processing with newforms?? Rob On Feb 14, 1:49 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > On Thu, 2008-02-14 at 10:20 -0800, robstar wrote: > > [...] > > > > > I'

Re: Multiple validation error handling in clean()

2008-02-14 Thread Malcolm Tredinnick
On Thu, 2008-02-14 at 10:20 -0800, robstar wrote: [...] > I'm not really sure how to process this list in the template.. or how > it gets stored for the correct field. Suppose I have this code in > clean(): > > rc = 0 > if 'captcha' in self.cleaned_data: > if not self

Re: Multiple validation error handling in clean()

2008-02-14 Thread robstar
Ok, I found some useful info posted by Malcolm: "Form.errors is an ErrorDict (from newforms.util), which maps field names to ErrorList instances. It is important to use ErrorList classes as the values in that dictionary, because they know how to display themselves properly. I'm not really alongs

Re: Multiple validation error handling in clean()

2008-02-14 Thread robstar
Oops, I found some info in search this might answer my question .. thanks anyway ! :) rob On Feb 14, 1:09 pm, robstar <[EMAIL PROTECTED]> wrote: > Hi guys, > > I'm working my way through the newforms and it's pretty cool.. but I'm > stumped on the error message handling from clean(). > > I

Multiple validation error handling in clean()

2008-02-14 Thread robstar
Hi guys, I'm working my way through the newforms and it's pretty cool.. but I'm stumped on the error message handling from clean(). I want to check the CAPTCHA input on the page (2 fields) as well as if the password fields match and return the error for each problem independently. clean() is sup