Skip to content

Commit

Permalink
Fixed #823 - cleaned up invalid HTML in debug error template. Thanks,…
Browse files Browse the repository at this point in the history
… Sune

git-svn-id: http://code.djangoproject.com/svn/django/trunk@1273 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information
jacobian committed Nov 17, 2005
1 parent b160356 commit bb505a8
Showing 1 changed file with 10 additions and 8 deletions.
18 changes: 10 additions & 8 deletions django/views/debug.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,6 +145,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
#requestinfo h3 { margin-bottom:-1em; }
</style>
<script type="text/javascript">
//<!--
function getElementsByClassName(oElm, strTagName, strClassName){
// Written by Jonathan Snook, http://www.snook.ca/jon; Add-ons by Robert Nyman, http://www.robertnyman.com
var arrElements = (strTagName == "*" && document.all)? document.all :
Expand Down Expand Up @@ -188,6 +189,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
s.innerHTML = s.innerHTML == uarr ? darr : uarr;
return false;
}
//-->
</script>
</head>
<body>
Expand Down Expand Up @@ -276,7 +278,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
<th>Value</th>
</tr>
</thead>
</tbody>
<tbody>
{% for var in request.GET.items %}
<tr>
<td>{{ var.0 }}</td>
Expand All @@ -286,7 +288,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
</tbody>
</table>
{% else %}
<p>No GET data<p>
<p>No GET data</p>
{% endif %}
<h3 id="post-info">POST</h3>
Expand All @@ -298,7 +300,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
<th>Value</th>
</tr>
</thead>
</tbody>
<tbody>
{% for var in request.POST.items %}
<tr>
<td>{{ var.0 }}</td>
Expand All @@ -308,7 +310,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
</tbody>
</table>
{% else %}
<p>No POST data<p>
<p>No POST data</p>
{% endif %}
<h3 id="cookie-info">COOKIES</h3>
Expand All @@ -320,7 +322,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
<th>Value</th>
</tr>
</thead>
</tbody>
<tbody>
{% for var in request.COOKIES.items %}
<tr>
<td>{{ var.0 }}</td>
Expand All @@ -330,7 +332,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
</tbody>
</table>
{% else %}
<p>No cookie data<p>
<p>No cookie data</p>
{% endif %}
<h3 id="meta-info">META</h3>
Expand All @@ -341,7 +343,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
<th>Value</th>
</tr>
</thead>
</tbody>
<tbody>
{% for var in request.META.items|dictsort:"0" %}
<tr>
<td>{{ var.0 }}</td>
Expand All @@ -360,7 +362,7 @@ def _get_lines_from_file(filename, lineno, context_lines):
<th>Value</th>
</tr>
</thead>
</tbody>
<tbody>
{% for var in settings.items|dictsort:"0" %}
<tr>
<td>{{ var.0 }}</td>
Expand Down

0 comments on commit bb505a8

Please sign in to comment.