Re: Passing parameters to form class

2011-06-01 Thread skyde
lated to django. This is what you get from trying to understand django with limited knowledge of python. Why I haven't had the time to study python is another matter alltogether... On Jun 1, 2:15 pm, Derek wrote: > On Jun 1, 11:39 am, skyde wrote: > > > Thank you very much!

Re: Passing parameters to form class

2011-06-01 Thread skyde
Thank you very much! I had not realised the self.fields['vaihtoehdot'] part! Best regards, skyde On Jun 1, 12:01 am, "christian.posta" wrote: > Yes, you will want to do this within the __init__ method. > > Run the super class's init method first so that ev

Passing parameters to form class

2011-05-31 Thread skyde
Hello, I've hit a brick wall while trying to create dynamic forms. Basically I am trying to give parameter to a class form and then based on that do a multiple choice questionaire. For example def somefunction(): formi = someForm(ids='1') class someForm(forms.Form): # get id from, use it