Luke Plant
c768bc6f25
Fixed #8031 - url tag no longer silences NoReverseMatch exceptions since this is very rarely useful
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8211 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-05 14:16:13 +00:00
Luke Plant
ff486b9fba
Fixed #3912 - Added simple type checking to template.Context.update() to help debugging broken context processors. Thanks Jeremy Dunck
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8181 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-08-01 21:37:38 +00:00
Malcolm Tredinnick
e29aece743
Fixed #4534 -- Added an "else" option to the "ifchanged" template tag.
...
Patch from SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@8095 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-07-26 22:09:43 +00:00
Adrian Holovaty
2c08986f44
Fixed #7417 -- Fixed ReST error in do_if() docstring. Thanks, Richard Bell <rbell01824@earthlink.net>
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7758 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-06-26 05:24:32 +00:00
Adrian Holovaty
9ef491b028
Optimized {% cycle %} template tag so that it creates the Variable objects in CycleNode.__init__() rather than each time render() is called
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7756 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-06-26 05:16:19 +00:00
Adrian Holovaty
dbde7fc8b0
Fixed #6322 -- Fixed bug in 'ifchanged' template tag where it wasn't resetting itself properly in some cases. Thanks, nedbatchelder
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7752 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-06-26 04:30:06 +00:00
Russell Keith-Magee
4317ba5799
Fixed #7318 -- Cleaned up the template inheritance logic, specifically to handle the case where the parent template has no template tags/blocks. Took the opportunity to optimize the logic a little. Thanks to Matthias Kestenholz <mk@spinlock.ch> for the original report and test case.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7688 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-06-18 12:59:39 +00:00
Russell Keith-Magee
0433ffa6f6
Fixed #7293 -- Corrected some doctests strings internal to the template module. Thanks, akaihola.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7580 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-06-06 13:58:42 +00:00
Russell Keith-Magee
d53e8f1285
Fixed #6430 -- Corrected the loading of templates from eggs, which was broken by the unicode merge. Thanks for the excellent report and patch, Juan Manuel Caicedo <juan.manuel.caicedo@gmail.com>.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7565 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-05-29 13:11:23 +00:00
Russell Keith-Magee
f696c175d8
Fixed #6950 -- Modified initialization of template loaders to use a temporary variable instead of directly modifying the global loader list. Thanks, mrts.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7563 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-05-29 12:40:25 +00:00
Russell Keith-Magee
55d5f7ecf4
Fixed #7301 -- Corrected minor typo in docstring. Thanks, micahcowan.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7557 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-05-29 11:42:55 +00:00
Malcolm Tredinnick
516102dc75
FIxed #6513 -- Handle overflows better in the floatformat filter. It's not
...
possible to test this automatically everywhere due to differing representations
on different platforms. Manual testing confirms it works, though.
Thanks, Karen Tracey.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7336 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-03-20 07:36:33 +00:00
Malcolm Tredinnick
b5adaec4c2
Fixed #5884 -- Added better display error handling for template variables.
...
Combined work from Karen Tracey and Thomas Güttler.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7260 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-03-17 14:21:09 +00:00
Gary Wilson Jr
5ca0b9203b
Fixed #5701 -- Fixed decorators to take the name, attributes, and docstring of the function they decorate by adding a modified version of the `functools.wraps` function from Python 2.5. `wraps` has been altered to work with Django's `curry` function and with Python 2.3, which doesn't allow assignment of a function's `__name__` attribute. This fixes severaly annoyances, such as the online documentation for template filters served by the admin app. This change is backwards incompatible if, for some reason, you were relying on the name of a Django decorator instead of the function it decorates.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7153 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-25 06:02:35 +00:00
Malcolm Tredinnick
00f96de5d6
Tweaked [7082] and [7084] a little bit to also allow comment nodes prior to the extends tag.
...
This would be little less fiddly if we knew nodelist were always of type
NodeList, but they could be normal lists. Or if we merged successive TextNodes,
instead of appending them. Something to think about going forwards.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7089 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-05 23:41:48 +00:00
Malcolm Tredinnick
0cdd65aa28
Fixed a simple TODO item in one error path of the "extends" tag.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7085 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-04 04:57:56 +00:00
Malcolm Tredinnick
b9e088ae14
Fixed #5124 -- Added a reasonable error when "extends" is not the first template tag. Patch from k0001.
...
Refs #6274 .
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7084 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-04 04:52:37 +00:00
Malcolm Tredinnick
10015fae4d
Allow whitespace prior to an "extends" tag. This allows a little more formatting flexibility. Refs #6274 .
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7082 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-04 02:31:53 +00:00
Gary Wilson Jr
f780ce6176
Fixed #6471 -- Fixed stringfilter decoration of `force_escape` filter.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7033 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-01-28 02:30:53 +00:00
Malcolm Tredinnick
a7da12d320
Fixed #5567 -- Added a "last" filter. Based on a patch from darkpixel.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6998 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-01-06 03:53:33 +00:00
Malcolm Tredinnick
1f6bc7ffa7
The "first" filter can return an unsafe string for safe input ( {{"<"|first}} ), so change is_safe to False. Refs #5567 .
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6997 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-01-06 03:53:04 +00:00
Adrian Holovaty
3d52ce730f
Reverted 'regroup' template tag changes from [6956], as they caused bug #6271 , which affects one of my sites. I don't have time to inspect the #6271 patch, so I'm reverting this change in the interim, to fix the bug immediately.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6996 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-01-05 00:03:12 +00:00
Adrian Holovaty
293f0f2360
Fixed #6295 -- Made the {% for %} tag a bit more efficient by creating a single context dictionary rather than recreating it each time through the loop. Thanks, Ned Batchelder
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6981 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-01-02 05:01:03 +00:00
Adrian Holovaty
e7b338d10e
Renamed 'reversed' variable to 'is_reversed' in ForLoop template tag implementation, to avoid potential conflicts with the 'reversed' built-in and to make the code more obvious
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6976 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:38:48 +00:00
Adrian Holovaty
abffdf5940
Negligible cleanups to django.template.context
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6975 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:32:54 +00:00
Adrian Holovaty
55ae4e00a7
Negligible changes to django.template -- removed a useless docstring, converted another one to a comment
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6974 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:30:13 +00:00
Adrian Holovaty
36a06edcdf
Removed lexer_factory() and parser_factory() functions in django.template, simplifying the compile_string() logic
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6973 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:28:21 +00:00
Adrian Holovaty
eb95a50cd6
Removed a comment in django/template/__init__.py that suggests we would do 'crazy stack-frame stuff'
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6972 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:20:02 +00:00
Adrian Holovaty
98d3da6389
Negligible formatting changes to django/template/__init__.py -- fixed some spacing issues, renamed NotImplemented to NotImplementedError and changed some 'raise' statements to use callable exceptions instead of the old-style comma technique
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6971 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:16:39 +00:00
Adrian Holovaty
6bcf1f0661
Changed an '== None' to 'is None' in Template.__init__()
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6970 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:12:58 +00:00
Adrian Holovaty
6557dc954b
Moved the various Debug classes in django.template to a new module, debug.py, so they're only loaded if DEBUG=True. This led to a DEBUG=False memory savings of one 4-KB memory block on my machine, according to ps
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6969 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-22 19:10:03 +00:00
Gary Wilson Jr
d1b5a0bde5
Removed some reverse string craziness from the regroup template tag argument checking and added a few syntax tests.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6956 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-19 06:11:55 +00:00
Malcolm Tredinnick
367867845f
Fixed #6239 -- Fixed an auto-escaping problem with urlizetrunc. Thanks, SmileyChris.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6950 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-19 04:20:02 +00:00
Malcolm Tredinnick
5d6f91e415
Small typo fixes. Thanks, jdetaeye, Ionut Ciocirlan, David Reynolds and adamv.
...
Fixed #6123 , #6133 , #6179 , #6194 .
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6923 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-17 06:59:01 +00:00
Jacob Kaplan-Moss
25f548a852
Fixed #6132 : note to self: when you add new template tags, you need to remember to actually register them. Thanks, Ben Walton.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6897 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-05 13:16:25 +00:00
Jacob Kaplan-Moss
b65fce6595
Fixed #4131 : added an "escapejs" filter for use in JavaScript strings, and updated the documentation on addslashes to point to the new ticket. Featuring contributions from Ned Batchelder, Jeremy Dunck, and Andy Durdin.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6892 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-04 21:08:29 +00:00
Malcolm Tredinnick
67373009e0
Fixed #4563 -- Context.pop/push/update return the top-level dictionary (the new
...
one for push() and update(), the one removed for pop()). Based on a patch from
Brian Harring.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6854 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-02 23:57:22 +00:00
Adrian Holovaty
a73588aa58
Edited docs/serialization.txt changes from [6645]
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6787 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-01 16:58:52 +00:00
Malcolm Tredinnick
8de4ed9c8c
Fixed #6057 -- Mark rendered template output as safe for auto-escaping purposes.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6778 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-30 15:32:01 +00:00
Malcolm Tredinnick
5d1d054e15
Fixed #6030 -- More robust error handling for the "float" filter. Thanks,
...
SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6752 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-29 20:10:00 +00:00
Malcolm Tredinnick
3c272792d6
Added tests and a small optimisation for [6721]. Thanks SmileyChris. Fixed #6049
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6729 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-29 01:44:30 +00:00
Malcolm Tredinnick
9130765ff9
Fixed #5890 -- fixed the far edge-case of allowing constant strings inside
...
template template markers: we now treat embedded, escaped double quotes
consistently with constant string arguments to filters. Patch from Dmitri
Fedortchenko.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6724 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-28 21:04:05 +00:00
Malcolm Tredinnick
dc716112a7
Fixed an edge-case for auto-escaping: if the stringfilter decorator is used and
...
generates a first argument that is a safe string, make the is_safe handling
work as expect.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6721 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-28 20:03:28 +00:00
Malcolm Tredinnick
2e9e36e297
Fixed #5983 -- Made iriencode filter respect safe strings. Patch from
...
SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6706 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-20 01:37:57 +00:00
Malcolm Tredinnick
0928fa5566
Fixed #5945 -- Treat string literals in template filter arguments as safe
...
strings for auto-escaping purposes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6680 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-17 12:11:26 +00:00
Malcolm Tredinnick
0b0ef3f0c5
Fixed #4713 -- Fixed handling of _() in template tag arguments. Based on
...
patched from Indy and SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6679 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-17 04:04:12 +00:00
Malcolm Tredinnick
bdb0b903c2
Content coming via {{ block.super }} is always going to be correctly escaped
...
already. We mark it as safe so that template authors don't need to.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6673 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-14 21:07:27 +00:00
Malcolm Tredinnick
356662cf74
Implemented auto-escaping of variable output in templates. Fully controllable by template authors and it's possible to write filters and templates that simulataneously work in both auto-escaped and non-auto-escaped environments if you need to. Fixed #2359
...
See documentation in templates.txt and templates_python.txt for how everything
works.
Backwards incompatible if you're inserting raw HTML output via template variables.
Based on an original design from Simon Willison and with debugging help from Michael Radziej.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6671 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-14 12:58:53 +00:00
Gary Wilson Jr
72b7a33929
`floatformat` template filter docstring changes:
...
* Split example cases.
* Corrected use with negative arguments (quotes are needed).
* Added another example of a number that has decimal places that include a non-zero digit and that ends with zeros.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6646 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-04 02:27:17 +00:00
Gary Wilson Jr
99697d9bec
Added examples to the `pluralize` template filter's docstring.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6643 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-04 02:08:04 +00:00
Gary Wilson Jr
4e8864a882
Style and import fixes.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6641 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-04 02:05:56 +00:00
Gary Wilson Jr
2a48fc5007
Made use of `itertools.cycle` for the `cycle` template tag.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6636 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-03 02:04:59 +00:00
Malcolm Tredinnick
b678601df3
Fixed #4123 -- Changed the firstof template tag to correctly handle a literal
...
string as its last argument. Thanks, Wesley Fok and Matt Boersma.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6571 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 15:01:31 +00:00
Malcolm Tredinnick
3e3a7e0258
Fixed a markup problem in the docstring for the "if" tag. This was showing up
...
in the admin docs.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6539 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 03:53:44 +00:00
Jacob Kaplan-Moss
2570954a9a
Fixed #3453 : introduced a new template variable resolution system by Brian Harring (thanks!). The upshot is that variable resolution is about 25% faster, and you should see a measurable performance increase any time you've got long or deeply nested loops.
...
Variable resolution has changed behind the scenes -- see the note in templates_python.txt -- but template.resolve_variable() still exists. This should be fully backwards-compatible.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6399 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-21 04:00:32 +00:00
Malcolm Tredinnick
d30badc0ec
Fixed #5243 -- Allow loading of templatetags from subdirectories (via dotted notation in {% load %}). Thanks, Bjørn Stabell.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6289 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 15:57:17 +00:00
Russell Keith-Magee
84e824fbbf
Fixed #3036 -- Fixed some doctest strings that were failing. Thanks to pterk for the original patch.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6268 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 08:29:56 +00:00
Adrian Holovaty
cadc6e8c9f
Fixed #4658 -- Improved documentation of linebreaks and linebreaksbr. Thanks, ubernostrum and Gary Wilson
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6223 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 21:46:38 +00:00
Jacob Kaplan-Moss
ad077ccbc0
Fixed #5445 : added some compatibility code for the lack of __iter__ in Jython 2.2. Thanks, Leo Soto.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6211 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 19:55:24 +00:00
Russell Keith-Magee
09145d2e5f
Fixed #208 -- Modernized the syntax of the cycle tag to allow for spaces and variables in cycle values. Thanks to SmileyChris and Chris McAvoy for their work on this.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6153 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 02:49:21 +00:00
Russell Keith-Magee
50497e3867
Refs #5138 -- Refactored implementation of __contains__ in HttpRequest introduced in [6097] after a suggestion from Malcolm. Applied a similar refactor for MergeDict and Context which had comparable behavior.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6098 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-11 14:04:40 +00:00
Gary Wilson Jr
1a1a58c9f8
Fixed #3184 -- Changed the `unordered_list` template filter to use a more simple format, while maintaining backwards compatibility with the old format. `unordered_list` now works with a simple list of items. Thanks for the patch, SmileyChris.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6019 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-26 01:11:20 +00:00
Malcolm Tredinnick
3b9b87792a
Fixed #5187 -- Minor doc tweaks. Thanks, Daniel Hahler.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5927 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-18 05:43:38 +00:00
Adrian Holovaty
3517550dac
Fixed #5006 -- Fixed incorrect/outdated docstring for the 'if' template tag. Thanks, Thomas Petazzoni
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5815 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-06 05:28:45 +00:00
Gary Wilson Jr
304381616f
Fixed #4952 -- Fixed the `get_template_sources` functions of the `app_directories` and `filesystem` template loaders to not return paths outside of given template directories. Both functions now make use of a new `safe_join` utility function. Thanks to SmileyChris for help with the patch.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5750 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-23 04:45:01 +00:00
Malcolm Tredinnick
e27a7ef360
Fixed #4842 -- Added slightly more robust error reporting. Thanks, Thomas
...
Güttler.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5682 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-13 10:56:30 +00:00
Malcolm Tredinnick
8c85ddf306
Fixed #4772 -- Fixed reverse URL creation to work with non-ASCII arguments.
...
Also included a test for non-ASCII strings in URL patterns, although that
already worked correctly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5630 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-07 18:24:27 +00:00
Malcolm Tredinnick
953badbea5
Merged Unicode branch into trunk (r4952:5608). This should be fully
...
backwards compatible for all practical purposes.
Fixed #2391 , #2489 , #2996 , #3322 , #3344 , #3370 , #3406 , #3432 , #3454 , #3492 , #3582 , #3690 , #3878 , #3891 , #3937 , #4039 , #4141 , #4227 , #4286 , #4291 , #4300 , #4452 , #4702
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5609 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-04 12:11:04 +00:00
Malcolm Tredinnick
fc20eeec47
Fixed a Python 2.3 incompatibility I overlooked in [5516].
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5517 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-23 06:02:17 +00:00
Malcolm Tredinnick
08aa5c585b
Fixed #4607 -- Tweaked checks for features missing in Python 2.3 to not assume
...
things Python does not guarantee. Patch from SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5514 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-23 03:18:22 +00:00
Malcolm Tredinnick
880e3cfaa6
Backed out the changes in [5482] for a bit whilst some more investigation into
...
side-effects is done. Refs #4565 .
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5511 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-22 07:15:04 +00:00
Malcolm Tredinnick
b0fa08b9e0
Trivial formatting changes.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5486 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-17 09:46:04 +00:00
Malcolm Tredinnick
2a34fbe043
Fixed #4506 -- Changed "regroup" template tag to use __eq__ instead of repr()
...
for grouping equality checking. Thanks, Brian Harring.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5484 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-17 07:33:18 +00:00
Malcolm Tredinnick
bccb8897e6
Fixed #4565 -- Changed template rendering to use iterators, rather than
...
creating large strings, as much as possible. This is all backwards compatible.
Thanks, Brian Harring.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5482 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-17 07:11:37 +00:00
Malcolm Tredinnick
03ecc00f6e
Fixed #4462 -- Use builtin reversed() function when available (in "for" tag).
...
Thanks, Brian Harring.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5454 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-10 03:11:10 +00:00
Russell Keith-Magee
16269c4d0a
Fixed #3523 -- Added list unpacking to for loops in templates. Thanks to SmileyChris and Honza Kral for their work.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5443 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-08 11:58:03 +00:00
Adrian Holovaty
603d5cc05a
Fixed #4441 -- Made a small optimization to the regroup template tag implementation. Thanks, ferringb@gmail.com
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5392 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-05-31 15:32:37 +00:00
Malcolm Tredinnick
dfdf7bdc5e
Fixed #4378 -- Fixed a broken format string.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5333 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-05-24 12:28:53 +00:00
Malcolm Tredinnick
faa31732ca
Fixed #3753 -- Allow optional display of invalid variable name in
...
TEMPLATE_STRING_IF_INVALID. Thanks, Matt McClanahan.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5167 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-05-08 03:36:16 +00:00
Malcolm Tredinnick
c675ee7612
Fixed #4180 -- Fixed docstring typo noticed by Gary Wilson.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5117 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-28 13:31:44 +00:00
Malcolm Tredinnick
4ac69165f8
Fixed #4176 -- Fixed unintended change introduced in [5104]. Thanks,
...
SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5116 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-28 04:45:38 +00:00
Malcolm Tredinnick
f30ca6636b
Minor tweak. Removed unnecessary argument default.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5105 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-27 12:27:19 +00:00
Malcolm Tredinnick
54f11ee63c
Fixed #4164 , #4171 -- Reworked some of the template lexer logic to ensure we
...
don't get caught out by a couple of corner cases.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5104 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-27 12:16:22 +00:00
Malcolm Tredinnick
439cb4047f
Fixed #4040 -- Changed uses of has_key() to "in". Slight performance
...
improvement and forward-compatible with future Python releases. Patch from Gary
Wilson.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5091 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-26 13:30:48 +00:00
Malcolm Tredinnick
aa1b182da3
Fixed #3543 -- Be a bit more tolerant of spaces following the comma
...
argument separator in the "url" tag.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5077 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-25 10:29:39 +00:00
Malcolm Tredinnick
76005c917f
Fixed #3948 -- Added some extra relevant information to FilterExpression
...
parse-related error message. Thanks, philippe.raoult@gmail.com .
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5067 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-25 07:05:31 +00:00
Malcolm Tredinnick
00cb6a1ba8
Fixed #4107 -- Marked a few more strings for translation. Thanks, Baptiste.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5061 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-23 05:51:29 +00:00
Malcolm Tredinnick
2a512a4e83
Fixed #3749 -- Set the context correctly when using the "filter" template tag.
...
Thanks, Zak Johnson.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5052 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-21 04:44:30 +00:00
Malcolm Tredinnick
539a7ab993
Fixed #4098 -- fixed a syntax error when reporting errors in "with" template
...
tag. Thanks cephelo@gmail.com .
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5048 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-21 04:13:52 +00:00
Malcolm Tredinnick
b6264d0452
Fixed #3887 -- Fixed formatting error in docstring that was causing problems in
...
online admin documentation. Thanks Florian Apolloner.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4909 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-03 03:45:47 +00:00
Russell Keith-Magee
9191fa1f64
Fixed #3532 -- Made spaceless template tag remove all spaces, rather than preserving a single space. Thanks for the suggestion, ampaze@gmx.net.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4885 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-01 01:09:21 +00:00
Adrian Holovaty
d22e39c10d
Fixed #3799 -- Added django.contrib.webdesign and moved 'lorem' template tag into there
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4857 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-30 01:50:06 +00:00
Russell Keith-Magee
5f68a26ff4
Fixes #3799 -- Oops - ran last checkin from the wrong directory. Checked in the rest of the lorem templatetag implementation.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4848 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-29 11:43:24 +00:00
Jacob Kaplan-Moss
d6fd9fb22b
Fixed #3826 : added a {% with %}. Thanks, SmileyChris.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4830 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-27 17:25:56 +00:00
Adrian Holovaty
6481cf43f9
Fixed #3808 -- Fixed some typos in comments. Thanks, Collin Grady
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4816 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-25 18:05:01 +00:00
Adrian Holovaty
515337fa3b
Small tweaks to docstrings from [4700]
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4747 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-16 15:20:37 +00:00
Malcolm Tredinnick
ee1ca89dd4
Fixed #3696 -- Fixed inline documentation to avoid some HTML validity issues.
...
Patch from Simon Greenhill.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4700 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-10 11:37:11 +00:00
Malcolm Tredinnick
659aa8f01a
Fixed #3693 -- Fixed RST error in floatformat docstring. Thanks, Simon
...
Greenhill.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4699 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-10 08:11:28 +00:00
Malcolm Tredinnick
8248569471
Fixed #3670 -- Fixed template argument parsing so that it understands negative
...
floats and integers as numeric types. Patch from SmileyChris.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4690 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-03-09 06:12:15 +00:00
Jacob Kaplan-Moss
19e0bf1d44
Fixed #3465 : template variable lookups like {{ foobar.13 }} now (correctly) fail silently on unsubscriptable objects. Thanks, Gary Wilson.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@4639 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-02-27 20:25:27 +00:00