This commit is contained in:
Sanj 2011-10-25 22:27:35 +01:00
parent f71af8182f
commit 7fa17fe8e3
2 changed files with 7 additions and 1 deletions

View File

@ -9,8 +9,8 @@ from django.forms.widgets import Textarea
from django.utils.html import urlize from django.utils.html import urlize
class ContactForm(forms.Form): class ContactForm(forms.Form):
email = forms.EmailField()
name = forms.CharField(max_length=255) name = forms.CharField(max_length=255)
email = forms.EmailField()
message = forms.CharField(widget=Textarea(attrs={'cols': 10, 'rows': 6})) message = forms.CharField(widget=Textarea(attrs={'cols': 10, 'rows': 6}))
''' '''

View File

@ -7,6 +7,12 @@
<table> <table>
{{ form.as_table }} {{ form.as_table }}
<tr>
<td>
</td>
<td>
<input type="submit" value="Submit" />
</td>
</table> </table>
</form> </form>
{% endblock %} {% endblock %}