On Sun, 2009-03-29 at 18:01 -0400, Vitaly Babiy wrote:
> Maybe I should have said why I ask.
> 
> I have a formset that the formset can not submit more than certain
> number of forms. I was not sure if max_num handles this or do I need
> to do this with some custom validation?


What happened when you tried it out?

In normal use it's not going to be possible to submit more than the
maximum number of formsets, since they won't be available in the HTML.
The only way it would be possible is if the user manually constructed
the POST request or you were messing about with things in Javascript and
made a mistake.

In both cases, I suspect the extra data will be ignored, just like any
other extra data in request.POST (designed that way so that you can pass
request.POST to a form constructor without having to know what's in the
form first). Since the "extra' forms that have been constructed only on
the client side won't match the prefix of any expected form, it will be
treated as extra data.

On the other hand, my first question is the easiest way to find the
answer.

Regards,
Malcolm


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to