I saw a solution on the list to format a datefield in a template.
Unfortunately i didnt find any solution for formatting a datefield in
a mailform. I have this in my model:

  Aankomst = forms.DateField(('%d/%m/%Y',), widget=forms.DateTimeInput
(format='%d/%m/%Y', attrs={
                        'class':'formVeld',
                        'readonly':'readonly',
                        'size':'8'
                        }), required=False)

This is a part of my view:

                        Aankomst = form.cleaned_data['Aankomst']
                        aankomst = str(Aankomst)
                        message = aankomst

The date output in my mail is:

2010-07-30

I would like it to have it as: 03/07/2010 Is there a solution for this?

--

You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-us...@googlegroups.com.
To unsubscribe from this group, send email to 
django-users+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en.


Reply via email to