diff options
| author | Tim Graham <timograham@gmail.com> | 2014-01-22 10:44:50 -0500 |
|---|---|---|
| committer | Tim Graham <timograham@gmail.com> | 2014-01-22 10:45:10 -0500 |
| commit | a4c32d70c2bcf9731b6d6ff3370d2260ab4812af (patch) | |
| tree | 49e577f865b87819ceae74c46489d6d0a207f5c8 | |
| parent | f7c2852f30fd5fe6980d6983725a41e64c6d2c53 (diff) | |
[1.6.x] Fixed #21529 -- Noted that {% url %} encodes its output (refs #13260).
Backport of dfc092622e from master
| -rw-r--r-- | docs/ref/templates/builtins.txt | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/docs/ref/templates/builtins.txt b/docs/ref/templates/builtins.txt index 6d1ca6b42c..34a20d69ef 100644 --- a/docs/ref/templates/builtins.txt +++ b/docs/ref/templates/builtins.txt @@ -997,9 +997,15 @@ url ^^^ Returns an absolute path reference (a URL without the domain name) matching a -given view function and optional parameters. This is a way to output links -without violating the DRY principle by having to hard-code URLs in your -templates:: +given view function and optional parameters. + +.. versionchanged:: 1.6 + + Any special characters in the resulting path will be encoded using + :func:`~django.utils.encoding.iri_to_uri`. + +This is a way to output links without violating the DRY principle by having to +hard-code URLs in your templates:: {% url 'path.to.some_view' v1 v2 %} |
