Create a form with a CharField, URLField, etc e.g:
class ElectionSourceForm(forms.Form):
source = forms.CharField(required=True, max_length=1000,
label="Where did you find out about this election?")
render it with {{ form|dc_form }}
Expected output:
<div class="form-group">
<label class="control-label " for="id_source-source">Where did you find out about this election?</label>
<div class=" ">
<input class=" form-control" id="id_source-source" maxlength="1000" name="source-source" type="text" required />
</div>
</div>
Observed output:
<div class="form-group">
<label >
Where did you find out about this election?
</label>
<label class="control-label " for="id_source-source">Where did you find out about this election?</label>
<div class=" ">
<input class=" form-control" id="id_source-source" maxlength="1000" name="source-source" type="text" required />
</div>
</div>
Steps to reproduce:
CharField
,URLField
, etc e.g:{{ form|dc_form }}
Expected output:
Observed output: