Django

Code

Show
Ignore:
Timestamp:
09/08/08 00:19:28 (3 months ago)
Author:
adrian
Message:

Fixed #8172 -- Improved a whole bunch of contrib templates (admin, databrowse, admindocs, etc.) to remove unnecessary 'escape' filters, given autoescaping. Also removed unnecessary {% if %} tags and shortened some {% if %}/{% else %} tags to use {% firstof %}. Thanks for the patch, benspaulding

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • django/trunk/django/views/static.py

    r6939 r8984  
    7474    <meta http-equiv="Content-Language" content="en-us" /> 
    7575    <meta name="robots" content="NONE,NOARCHIVE" /> 
    76     <title>Index of {{ directory|escape }}</title> 
     76    <title>Index of {{ directory }}</title> 
    7777  </head> 
    7878  <body> 
    79     <h1>Index of {{ directory|escape }}</h1> 
     79    <h1>Index of {{ directory }}</h1> 
    8080    <ul> 
     81      {% ifnotequal directory "/" %} 
     82      <li><a href="../">../</a></li> 
     83      {% endifnotequal %} 
    8184      {% for f in file_list %} 
    82       <li><a href="{{ f|urlencode }}">{{ f|escape }}</a></li> 
     85      <li><a href="{{ f|urlencode }}">{{ f }}</a></li> 
    8386      {% endfor %} 
    8487    </ul>