diff options
| author | Claude Paroz <claude@2xlibre.net> | 2014-03-22 21:30:49 +0100 |
|---|---|---|
| committer | Claude Paroz <claude@2xlibre.net> | 2014-03-22 21:32:20 +0100 |
| commit | 3a97f992fbfbcf8b0480875b257e5d541a4b8315 (patch) | |
| tree | c5ac40df266f098c5b7b1378864685869fe2a324 /docs/ref/unicode.txt | |
| parent | 232181d1c5307d9af5fc292682661e91439a9289 (diff) | |
Fixed #22313 -- Removed 'u' prefixes from documentation
Diffstat (limited to 'docs/ref/unicode.txt')
| -rw-r--r-- | docs/ref/unicode.txt | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/docs/ref/unicode.txt b/docs/ref/unicode.txt index 306a2dfb48..d8581e801c 100644 --- a/docs/ref/unicode.txt +++ b/docs/ref/unicode.txt @@ -201,9 +201,9 @@ like that. An example might clarify things here:: - >>> urlquote(u'Paris & Orléans') - u'Paris%20%26%20Orl%C3%A9ans' - >>> iri_to_uri(u'/favorites/François/%s' % urlquote('Paris & Orléans')) + >>> urlquote('Paris & Orléans') + 'Paris%20%26%20Orl%C3%A9ans' + >>> iri_to_uri('/favorites/François/%s' % urlquote('Paris & Orléans')) '/favorites/Fran%C3%A7ois/Paris%20%26%20Orl%C3%A9ans' If you look carefully, you can see that the portion that was generated by @@ -279,7 +279,7 @@ above_. For example:: from django.utils.http import urlquote def get_absolute_url(self): - url = u'/person/%s/?x=0&y=0' % urlquote(self.location) + url = '/person/%s/?x=0&y=0' % urlquote(self.location) return iri_to_uri(url) This function returns a correctly encoded URL even if ``self.location`` is |
