diff options
| author | Gary Wilson Jr <gary.wilson@gmail.com> | 2009-03-30 20:33:42 +0000 |
|---|---|---|
| committer | Gary Wilson Jr <gary.wilson@gmail.com> | 2009-03-30 20:33:42 +0000 |
| commit | 487a7fdccee5b71f1f44acaafbaec58fa05120d5 (patch) | |
| tree | e863773ade77bf03dd9c7c5d9bd67e1d0ef8cfe3 /django | |
| parent | daae84a8e0c292b77aabd5719d3022df72f47fc8 (diff) | |
[1.0.X]: Fixed #10094 -- Fixed the `include` and `extends` template tags to work with filenames with spaces, patch from mcroydon.
Backport of r10211 from trunk.
git-svn-id: http://code.djangoproject.com/svn/django/branches/releases/1.0.X@10212 bcc190cf-cafb-0310-a4f2-bffc1f526a37
Diffstat (limited to 'django')
| -rw-r--r-- | django/template/loader_tags.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/django/template/loader_tags.py b/django/template/loader_tags.py index 38b2fff9fd..f91699d7f2 100644 --- a/django/template/loader_tags.py +++ b/django/template/loader_tags.py @@ -158,7 +158,7 @@ def do_extends(parser, token): name of the parent template to extend (if it evaluates to a string) or as the parent tempate itelf (if it evaluates to a Template object). """ - bits = token.contents.split() + bits = token.split_contents() if len(bits) != 2: raise TemplateSyntaxError, "'%s' takes one argument" % bits[0] parent_name, parent_name_expr = None, None @@ -179,7 +179,7 @@ def do_include(parser, token): {% include "foo/some_include" %} """ - bits = token.contents.split() + bits = token.split_contents() if len(bits) != 2: raise TemplateSyntaxError, "%r tag takes one argument: the name of the template to be included" % bits[0] path = bits[1] |
