? my $app = shift;
<html>
  <head>
    <title>Logs</title>
    <link type="text/css" rel="stylesheet" href="/static/site.css" />
    <script type="text/javascript" src="/static/alice.js"></script>
    <script type="text/javascript">
      sendQuery = function (form) {
        new Ajax.Request("/search", {
          method: "get",
          parameters: form.serialize(),
          onSuccess: function (transport) {
            $('logresults').replace(transport.responseText);
          }
        });
        return false;
      };
      
      expandRange = function(channel, time, li) {
        new Ajax.Request('/range', {
          method: "post",
          parameters: {time: time, channel: channel},
          onSuccess: function (transport) {
            $$('.context').each(function (item) {
              item.select(".context_wrapper").invoke("remove");
              item.removeClassName("context");
            });
            var data = transport.responseText;
            li.addClassName("context");
            data = data.evalJSON();
            li.insert({top: data[0], bottom: data[1]});
          }
        });
      };
    </script>
  </head>
  <body>
    <div id="logsearch">
<form id="query" onsubmit="return sendQuery(this)">
  <label for="nick">Nick</label><input size="8" type="text" name="nick" id="nick" />
  <label for="body">Content</label><input type="text" name="body" id="body" size="14" />
  <label for="channel">Channel</label><input size="8" type="text" name="channel" id="channel" />
  <input type="submit" value="Search" />
</form>
</div>
<ul id="logresults">
</ul>
</body>
</html>
