and you do that like so:
answer0 = forms.IntegerField(label='', widget=forms.CheckboxInput
(attrs={'value':0}))
for the next bloke that doesn't want to have to figure it out.
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Goo
> What is the proper way to assign a value to a single checkbox? Am I
> just stuck with boolean and true/false? That seems like a lot of
> extra work on the back end.
nevermind i just figured out to use a value attribute
--~--~-~--~~~---~--~~
You received this m
If i use the multiple Checkbox Input, It results in list of the items
which were selected.
My question is can you do the same thing for a single checkbox?
As an old ASP guy I'd do this:
I'm trying to do this in django by the following:
#...snip forms.py
el1_Choices = (
('EN', 'ENGLIS
3 matches
Mail list logo