This depends on your schema. If the datetype in your schema is a date or datetime, the output from the db.select statement should be a python datetime object. See this page:
http://docs.python.org/library/datetime.html Specifically the strftime method. Your template will probably involve something like: <li>$row.n...@$row.time.strftime("%b %d, %Y")</li> On May 26, 1:36 am, wolfv <[email protected]> wrote: > I have some record in sqlite ,every record have a time stamp; > I select them > ==== > resu = init.db.select('messages') > ==== > and use this code to print them in the template file > ====== > $for row in resu: > <li>$row.n...@$row.time Says:$row.cont</li> > ====== > but now I dont know how to print the time formated. > Need your help ! THX. -- You received this message because you are subscribed to the Google Groups "web.py" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/webpy?hl=en.
