From f870056f04d6837efa1da8897343fdd16c506513 Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Thu, 14 Jan 2016 19:24:24 +0000 Subject: [PATCH] added basic form --- project/common/forms.py | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 project/common/forms.py diff --git a/project/common/forms.py b/project/common/forms.py new file mode 100644 index 0000000..4cab9d0 --- /dev/null +++ b/project/common/forms.py @@ -0,0 +1,7 @@ +class ContactForm(forms.Form): + email = forms.CharField(label="Email Address", widget=forms.EmailInput(attrs={'placeholder': 'Email Address'})) + name = forms.CharField(label="Full Name", widget=forms.TextInput(attrs={'placeholder': 'Full Name'})) + message = forms.CharField(label="Message", widget=forms.Textarea(attrs={'placeholder': 'Enter your message here'})) + + def send_email(self): + print("Sending email with", self.cleaned_data)