Author: adrian
Date: 2006-07-10 09:22:04 -0500 (Mon, 10 Jul 2006)
New Revision: 3312
Modified:
django/trunk/docs/templates_python.txt
Log:
Decimated 'whilst' in docs/templates_python.txt from [3308]
Modified: django/trunk/docs/templates_python.txt
===================================================================
--- django/trunk/docs/templates_python.txt 2006-07-10 14:14:32 UTC (rev
3311)
+++ django/trunk/docs/templates_python.txt 2006-07-10 14:22:04 UTC (rev
3312)
@@ -669,9 +669,11 @@
* ``token.contents`` is a string of the raw contents of the tag. In our
example, it's ``'current_time "%Y-%m-%d %I:%M %p"'``.
- * The ``token.split_contents()`` method separates the arguments on spaces,
- whilst keeping quoted strings together. The more straightforward
- ``token.contents.split()`` would be as robust.
+ * The ``token.split_contents()`` method separates the arguments on spaces
+ while keeping quoted strings together. The more straightforward
+ ``token.contents.split()`` wouldn't be as robust, as it would naively
+ split on *all* spaces, including those within quoted strings. It's a good
+ idea to always use ``token.split_contents()``.
* This function is responsible for raising
``django.template.TemplateSyntaxError``, with helpful messages, for
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django updates" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-updates
-~----------~----~----~----~------~----~------~--~---