I think this may help http://www.magpiebrain.com/2005/08/21/formatting-dates-with-django/
try using strftime and formatting from there. On Mar 8, 3:16 pm, "het.oosten" <het.oos...@gmail.com> wrote: > I forgot to mention that my desired output of the date is: > 2010-02-22 20:46:03 > > On 8 mrt, 22:13, "het.oosten" <het.oos...@gmail.com> wrote: > > > I am getting somewhere now: > > > import datetime > > import time > > import twitter > > > tweet = twitter.Api().GetUserTimeline('username', count=3) > > for s in tweet: > > s.date = datetime.datetime(*(time.strptime( s.created_at,"%a > > %b %d %H:%M:%S +0000 %Y" )[0:6])) > > print [x.text for x in tweet] > > print [y.date for y in tweet] > > > However the output is now: > > [datetime.datetime(2010, 3, 1, 16, 51, 55), datetime.datetime(2010, 2, > > 22, 20, 46, 3), datetime.datetime(2010, 2, 20, 10, 16, 2)] > > > I still miss a little thing to complete........anybody a little hint? -- 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.