2018-10-11 12:33:40 -05:00

26 lines
1.0 KiB
Python

from django import forms
class ContactForm(forms.Form):
name = forms.CharField(label="Nombre",
required=True,
widget=forms.TextInput(
attrs={'placeholder': 'Nombre'}
),
min_length=3,
max_length=100)
email = forms.EmailField(label="Email",
required=True,
widget=forms.EmailInput(
attrs={'placeholder': 'user@page.domain'}
),
min_length=3,
max_length=100)
content = forms.CharField(label="Mensaje",
required=True,
widget=forms.Textarea(
attrs={'placeholder': 'Mensaje'}
),
min_length=10,
max_length=1000)