I went with the hidden fields, and it works very well. Thanks for your assistance!
Vincent On Jan 23, 2:06 pm, "Aidas Bendoraitis" <[EMAIL PROTECTED]> wrote: > 1. You can just have a hidden field defining the manipulator in each form. > > data = request.POST.copy() > if data["hidden_field"] == "reg1": > manipulator = RegistrMan1() > else: > manipulator = RegistrMan2() > > or smth similar. > > 2. Or you can do as Alex has already told: set different action urls > for different forms. You can have form1 as form2 as context variables > just not to mix up the validation errors and prepopulated values. > > Good luck! > Aidas Bendoraitis aka Archatas > > On 1/23/07, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > > > > > I imagine it would. However, what happens with repopulation of the > > fields if validation fails? If my view is called subscription(), I > > usually do something like: > > > def subscription(request): > > ... > > if request.method == 'POST': > > data = request.POST.copy() > > errors = manipulator.get_validation_errors() > > ... > > form = forms.FormWrapper(manipulator, data, errors) > > return render_to_response('subscribe.html', {'form': form}) > > > I wonder how I will know which maniplator class to use. I'm not sure > > if I'm clear, but it's sort of messed up in my head. --~--~---------~--~----~------------~-------~--~----~ 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 [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---