view commentator/templates/comment.html @ 2:689b9d928dc8

add date, reflect api change of lxmlmiddleware
author k0s <k0scist@gmail.com>
date Tue, 26 Jan 2010 23:00:51 -0500
parents 1c95a3fa76c1
children
line wrap: on
line source

<!DOCTYPE html
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
    "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:py="http://genshi.edgewall.org/"
      xmlns:xi="http://www.w3.org/2001/XInclude"
      py:strip="True">
<div class="comments">
  <div py:for="comment in comments" class="comment">
    <a py:strip="not comment['link']" href="${comment['link']}">
      ${comment['author']}
    </a>${comment['date'].strftime(date_format)}
    <p>${comment['body']}</p>
  </div>

  
  <form method="post" action="${action}">

  <py:if test="bool(request.remote_user)">
  <input type="hidden" name="author" value="${request.remote_user}"/>
  </py:if> 
    <dl>
    <py:if test="not request.remote_user">
      <dt>Name:</dt><dd><input type="text" name="author"/></dd>
      </py:if>
      <dt>URL:</dt><dd><input type="text" name="link"/></dd>
      <textarea name="body"></textarea>
    </dl>
    <input type="submit" value="Comment"/>
  </form>
</div>
</html>