#21306: Fix (or document) lower-casing behavior of title filter
---------------------------------+------------------------------------
     Reporter:  timo             |                    Owner:  nobody
         Type:  Uncategorized    |                   Status:  new
    Component:  Template system  |                  Version:  1.4
     Severity:  Normal           |               Resolution:
     Keywords:                   |             Triage Stage:  Accepted
    Has patch:  0                |      Needs documentation:  0
  Needs tests:  0                |  Patch needs improvement:  0
Easy pickings:  1                |                    UI/UX:  0
---------------------------------+------------------------------------
Changes (by bmispelon):

 * cc: bmispelon@… (added)
 * component:  Uncategorized => Template system
 * easy:  0 => 1
 * stage:  Unreviewed => Accepted


Comment:

 That behavior is consistent with python's `str.title` method [1].

 Django's `title` function has two features on top of `str.title`:
 * `title("isn't it") == "Isn't It"` (whereas `"isn't it".title() == "Isn'T
 It`)
 * `title("8foo") == "8foo"` (whereas `"8foo".title() == "8Foo"`)

 I don't think we can fix this particular issue without breaking backwards-
 compatibility so I think documenting it is the best course of action.

 [1]
 http://docs.python.org/2/library/stdtypes.html?highlight=str.title#str.title

-- 
Ticket URL: <https://code.djangoproject.com/ticket/21306#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/062.106da455447c7017e00a4aea355ca9e5%40djangoproject.com.
For more options, visit https://groups.google.com/groups/opt_out.

Reply via email to