{# This template mimics the apache directory index page almost exactly. #}

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<html>

<head>
  <title>Index of {{ request.path }}</title>
</head>

<body>
  <h1>Index of {{ request.path }}</h1>
  <table>
    <tr>
      <th valign="top"><img src="https://www.apache.org/icons/blank.gif" alt="[ICO]" /></th>
      <th><a href="?C=N;O=D">Name</a></th>
      <th><a href="?C=M;O=A">Last modified</a></th>
      <th><a href="?C=S;O=A">Size</a></th>
      <th><a href="?C=D;O=A">Description</a></th>
    </tr>
    <tr>
      <th colspan="5">
        <hr>
      </th>
    </tr>
    <tr>
      <td valign="top"><img src="https://www.apache.org/icons/back.gif" alt="[PARENTDIR]" /></td>
      <td><a href="{{ parent_url }}">Parent Directory</a></td>
      <td>&nbsp;</td>
      <td align="right">-</td>
      <td>&nbsp;</td>
    </tr>
    {# Loop over all directories #}
    {% for directory_data in directories %}
    <tr>
      <td valign="top"><img src="https://www.apache.org/icons/folder.gif" alt="[DIR]" /></td>
      <td><a href="{{ directory_data.url }}">{{ directory_data.name }}</a></td>
      <td align="right">{{ directory_data.last_modified }}</td>
      <td align="right">-</td> {# no size for directories #}
      <td>&nbsp;</td> {# no description for directories #}
    </tr>
    {% endfor %}
    {% for file_data in files %}
    <tr>
      <td valign="top"><img src="https://www.apache.org/icons/{{ file_data.icon_name }}" alt="[FILE]" /></td>
      <td><a href="{{ file_data.url }}">{{ file_data.name }}</a></td>
      <td align="right">{{ file_data.last_modified }}</td>
      <td align="right">{{ file_data.size }}</td>
      <td align="right">{{ file_data.description }}</td>
    </tr>
    {% endfor %}
    <tr>
      <th colspan="5">
        <hr />
      </th>
    </tr>
  </table>
</body>

</html>

{% comment %}
vi: ft=htmldjango
{% endcomment %}
