Re: Newforms validation error not displayed:

2007-11-04 Thread Karen Tracey
On 11/4/07, crybaby <[EMAIL PROTECTED]> wrote: > > > That seems to be a silly question now. I have another related > question regarding type of "self.cleaned_data['guess_the_number']", > string or integer or float? In general it depends on the type of field. In this case it's a RegExField, so

Re: Newforms validation error not displayed:

2007-11-04 Thread crybaby
That seems to be a silly question now. I have another related question regarding type of "self.cleaned_data['guess_the_number']", string or integer or float? --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Djang

Re: Newforms validation error not displayed:

2007-11-03 Thread RajeshD
> > def clean_guess_the_number(self): > if self.max_number > self.cleaned_data['guess_the_number']: Change that to: if self.max_number < self.cleaned_data['guess_the_number']: > raise forms.ValidationError('Your Number have to be lower > or equal to Max Number.') >

Re: Newforms validation error not displayed:

2007-11-03 Thread Karen Tracey
On 11/3/07, crybaby <[EMAIL PROTECTED]> wrote: > > > Validation checks the number entered by the user is between the range > and this check is done in "def clean_guess_the_number". This is not > working. > > Seems like "def clean_guess_the_number(self)" never executed when you > post the data and

Newforms validation error not displayed:

2007-11-03 Thread crybaby
Validation checks the number entered by the user is between the range and this check is done in "def clean_guess_the_number". This is not working. Seems like "def clean_guess_the_number(self)" never executed when you post the data and when form.is_valid() called. class GuessForm(forms.Form):