The label Comment Text
kept appearing on the form.
By adding the labels dictionary in the form
file, I was able to get rid of the label.
class CommentForm(forms.ModelForm):
class Meta:
model = Comment
fields = ['comment_text', ]
labels = {
"comment_text": ""
}
Top comments (1)
You can also add the init method and assign your field label as empty.
I have attached a picture.