This behaves in a somewhat similar manner and as far as I have gone through this and tested, I am pretty happy with this. But I would still prefer having some HTML5 attributes with fallback javascript as well. Since these new html5 features are becoming more and more popular among the web developers, so we must get them into django also as much as possible.Any thoughts ?
On 8 February 2012 15:58, Karthik Abinav <[email protected]> wrote: > > > On 7 February 2012 10:01, Tai Lee <[email protected]> wrote: > >> I found that Alex's `django-ajax-validation` works pretty well for >> this and I think it works the way you described. Perhaps it could be >> updated and included into Django core, if there is good support for >> it. >> >> https://github.com/alex/django-ajax-validation/ >> >> > @Tai: Thanks a lot for the link.Though I havent personally gone through > this code yet(I will be doing so in 2 -3 days.) If this behaves exactly as > requested by me above then, I think it will be a great idea to include this > into the main django repo if there is a good support for this > implementation. > > > >> Cheers. >> Tai. >> >> >> On Feb 4, 8:03 am, Adrian Holovaty <[email protected]> wrote: >> > On Fri, Feb 3, 2012 at 11:46 AM, Karthik Abinav >> > >> > <[email protected]> wrote: >> > > I was thinking about a feature that could be implemented. For common >> > > fields like username having only alphanumeric , or phone numbers >> having only >> > > numbers, a client side validation need not be written every >> time.Instead one >> > > could directly write something like, >> > >> > > forms.CharField(validator = "usernamevalidation") >> > >> > > in the forms definition and the client side validation for that field >> would >> > > automatically be taken care of by the validator class. This will save >> a lot >> > > of time while making large websites with lot of registration forms >> and in >> > > general be helpful to people who dont really know javascript and yet >> want >> > > some amount of frontend validation in place. >> > >> > I like the idea of having a JavaScript version of form validation. >> > Basically we could make a view class that takes a Form object in >> > __init__() and returns JSON of the errors in a consistent way -- this >> > would be very easy to do. Then we could provide some standard >> > JavaScript to parse that JSON and add the error messages to the >> > appropriate fields in the form in a consistent way. >> > >> > Good idea! It's a bit too late now to add it to Django 1.4, but I'd >> > like to implement this for the next version. >> > >> > Adrian >> >> -- >> You received this message because you are subscribed to the Google Groups >> "Django developers" group. >> To post to this group, send email to [email protected]. >> To unsubscribe from this group, send email to >> [email protected]. >> For more options, visit this group at >> http://groups.google.com/group/django-developers?hl=en. >> >> > > > Regards, > > Karthik Abinav, > > -- Regards, Karthik Abinav, -- You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/django-developers?hl=en.
