Mercurial > libervia-web
comparison server_side/blog.py @ 15:78bfc398926b
public blog is now shown i reverse order
author | Goffi <goffi@goffi.org> |
---|---|
date | Sat, 09 Apr 2011 13:14:39 +0200 |
parents | 513fe9bd0665 |
children | 9d8e79ac4c9c |
comparison
equal
deleted
inserted
replaced
14:9bf8ed012adc | 15:78bfc398926b |
---|---|
72 <title>%(user)s's microblog</title> | 72 <title>%(user)s's microblog</title> |
73 </head> | 73 </head> |
74 <body> | 74 <body> |
75 <div class='mblog_title'>%(user)s</div> | 75 <div class='mblog_title'>%(user)s</div> |
76 """ % {'user':user}) | 76 """ % {'user':user}) |
77 mblog_data.reverse() | |
77 for entry in mblog_data: | 78 for entry in mblog_data: |
78 timestamp = float(entry.get('timestamp',0)) | 79 timestamp = float(entry.get('timestamp',0)) |
79 _datetime = datetime.fromtimestamp(timestamp) | 80 _datetime = datetime.fromtimestamp(timestamp) |
80 request.write("<div class='mblog_content'><span class='mblog_timestamp'>%(date)s</span>%(content)s</div>" % { | 81 request.write("<div class='mblog_content'><span class='mblog_timestamp'>%(date)s</span>%(content)s</div>" % { |
81 'date':_datetime, | 82 'date':_datetime, |