Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Fixed #1102 -- Fixed some HTML validation errors in admin templates. …

…Thanks, Luke Plant

git-svn-id: http://code.djangoproject.com/svn/django/trunk@1791 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 632914f1887ecc3e0a2499a7ba257e1575c7b74e 1 parent 5f47ce0
Adrian Holovaty authored December 28, 2005
4  django/contrib/admin/templates/admin/change_list_results.html
... ...
@@ -1,3 +1,4 @@
  1
+{% if results %}
1 2
 <table cellspacing="0">
2 3
 <thead>
3 4
 <tr>
@@ -7,7 +8,10 @@
7 8
 {% if header.sortable %}</a>{% endif %}</th>{% endfor %}
8 9
 </tr>
9 10
 </thead>
  11
+<tbody>
10 12
 {% for result in results %}
11 13
 <tr class="{% cycle row1,row2 %}">{% for item in result %}{{ item }}{% endfor %}</tr>
12 14
 {% endfor %}
  15
+</tbody>
13 16
 </table>
  17
+{% endif %}
4  django/contrib/admin/templates/admin/search_form.html
@@ -2,7 +2,8 @@
2 2
 {% load i18n %}
3 3
 {% if cl.lookup_opts.admin.search_fields %}
4 4
 <div id="toolbar"><form id="changelist-search" action="" method="get">
5  
-<label><img src="{% admin_media_prefix %}img/admin/icon_searchbox.png" /></label>
  5
+<div><!-- DIV needed for valid HTML -->
  6
+<label><img src="{% admin_media_prefix %}img/admin/icon_searchbox.png" alt="Search" /></label>
6 7
 <input type="text" size="40" name="{{ search_var }}" value="{{ cl.query|escape }}" id="searchbar" />
7 8
 <input type="submit" value="{% trans 'Go' %}" />
8 9
 {% if show_result_count %}
@@ -11,6 +12,7 @@
11 12
 {% for pair in cl.params.items %}
12 13
     {% ifnotequal pair.0 search_var %}<input type="hidden" name="{{ pair.0|escape }}" value="{{ pair.1|escape }}"/>{% endifnotequal %}
13 14
 {% endfor %}
  15
+</div>
14 16
 </form></div>
15 17
 <script type="text/javascript">document.getElementById("searchbar").focus();</script>
16 18
 {% endif %}

0 notes on commit 632914f

Please sign in to comment.
Something went wrong with that request. Please try again.