Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

newforms-admin: Fixed #7391 -- Mark the output of BaseFormSet.as_tabl…

…e safe. Thanks akaihola!

git-svn-id: http://code.djangoproject.com/svn/django/branches/newforms-admin@7587 bcc190cf-cafb-0310-a4f2-bffc1f526a37
  • Loading branch information...
commit 65ef8d4da78c94a8b1da5ac058f1b85b942f58ae 1 parent 453d560
@brosner brosner authored
Showing with 2 additions and 1 deletion.
  1. +2 −1  django/newforms/formsets.py
View
3  django/newforms/formsets.py
@@ -1,5 +1,6 @@
from forms import Form
from django.utils.encoding import StrAndUnicode
+from django.utils.safestring import mark_safe
from fields import IntegerField, BooleanField
from widgets import Media, HiddenInput, TextInput
from util import ErrorList, ValidationError
@@ -258,7 +259,7 @@ def as_table(self):
# probably should be. It might make sense to render each form as a
# table row with each field as a td.
forms = u' '.join([form.as_table() for form in self.forms])
- return u'\n'.join([unicode(self.management_form), forms])
+ return mark_safe(u'\n'.join([unicode(self.management_form), forms]))
# XXX: This API *will* change. Use at your own risk.
def _formset_factory(form, formset=BaseFormSet, extra=1, can_order=False, can_delete=False):

0 comments on commit 65ef8d4

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