Django

Code

Ticket #1387 (closed: fixed)

Opened 3 years ago

Last modified 2 years ago

some xml parsing errors in firefox

Reported by: vineet Assigned to: adrian
Milestone: Component: RSS framework
Version: new-admin Keywords:
Cc: Triage Stage: Unreviewed
Has patch: 0 Needs documentation: 0
Needs tests: 0 Patch needs improvement: 0

Description

I've noticed a few problems with pages that won't render due to having some invalid XML. Here's a patch fixing 2 of them:

Index: django/contrib/admin/templates/admin/change_form.html
===================================================================
--- django/contrib/admin/templates/admin/change_form.html       (revision 2368)
+++ django/contrib/admin/templates/admin/change_form.html       (working copy)
@@ -21,7 +21,7 @@
   </ul>
 {% endif %}{% endif %}
 <form {{ bound_manipulator.form_enc_attrib }} action="{{ form_url }}" method="post">{% block form_top %}{% endblock %}
-{% if is_popup %}<input type="hidden" name="_popup" value="1">{% endif %}
+{% if is_popup %}<input type="hidden" name="_popup" value="1"/>{% endif %}
 {% if bound_manipulator.save_on_top %}{% submit_row bound_manipulator %}{% endif %}
 {% if form.error_dict %}
     <p class="errornote">
Index: django/contrib/admin/templates/admin_doc/bookmarklets.html
===================================================================
--- django/contrib/admin/templates/admin_doc/bookmarklets.html  (revision 2368)
+++ django/contrib/admin/templates/admin_doc/bookmarklets.html  (working copy)
@@ -16,7 +16,7 @@
 {% endblocktrans %}
 
 <div id="content-main">
-    <h3><a href="javascript:(function(){if(typeof ActiveXObject!='undefined'){x=new ActiveXObject('Microsoft.XMLHTTP')}else if(typeof XMLHttpRequest!='undefined'){x=new XMLHttpRequest()}else{return;}x.open('HEAD',location.href,false);x.send(null);try{view=x.getResponseHeader('x-view');}catch(e){alert('No view found for this page');return;}if(view=="undefined"){alert("No view found for this page");}document.location='{{ admin_url }}doc/views/'+view+'/';})()">{% trans "Documentation for this page" %}</a></h3>
+    <h3><a href="javascript:(function(){if(typeof ActiveXObject!='undefined'){x=new ActiveXObject('Microsoft.XMLHTTP')}else if(typeof XMLHttpRequest!='undefined'){x=new XMLHttpRequest()}else{return;}x.open('HEAD',location.href,false);x.send(null);try{view=x.getResponseHeader('x-view');}catch(e){alert('No view found for this page');return;}if(view=='undefined'){alert('No view found for this page');}document.location='{{ admin_url }}doc/views/'+view+'/';})()">{% trans "Documentation for this page" %}</a></h3>
     <p>{% trans "Jumps you from any page to the documentation for the view that generates that page." %}</p>

     <h3><a href="javascript:(function(){if(typeof ActiveXObject!='undefined'){x=new ActiveXObject('Microsoft.XMLHTTP')}else if(typeof XMLHttpRequest!='undefined'){x=new XMLHttpRequest()}else{return;}x.open('GET',location.href,false);x.send(null);try{type=x.getResponseHeader('x-object-type');id=x.getResponseHeader('x-object-id');}catch(e){type='(none)';id='(none)';}d=document;b=d.body;e=d.createElement('div');e.id='xxxhhh';s=e.style;s.position='absolute';s.left='10px';s.top='10px';s.font='10px monospace';s.border='1px black solid';s.padding='4px';s.backgroundColor='#eee';e.appendChild(d.createTextNode('Type: '+type));e.appendChild(d.createElement('br'));e.appendChild(d.createTextNode('ID: '+id));e.appendChild(d.createElement('br'));l=d.createElement('a');l.href='#';l.onclick=function(){b.removeChild(e);};l.appendChild(d.createTextNode('[close]'));l.style.textDecoration='none';e.appendChild(l);b.appendChild(e);})();">{% trans "Show object ID" %}</a></h3>

Attachments

Change History

02/23/06 13:05:40 changed by adrian

  • status changed from new to closed.
  • resolution set to fixed.

(In [2371]) Fixed #1387 -- Fixed some XHTML errors in admin templates. Thanks, vineet

07/03/06 02:11:44 changed by anonymous

  • priority changed from normal to low.
  • type changed from defect to task.
  • component changed from Admin interface to Translations.
  • severity changed from normal to minor.
  • milestone set to Version 1.1.

07/07/06 14:25:17 changed by anonymous

  • severity changed from minor to major.
  • component changed from Translations to RSS framework.
  • priority changed from low to high.
  • version set to new-admin.
  • milestone changed from Version 1.1 to Version 1.0.
  • type changed from task to defect.

01/17/07 16:12:17 changed by

  • milestone deleted.

Milestone Version 1.0 deleted


Add/Change #1387 (some xml parsing errors in firefox)




Change Properties
Action