Third-party titlecase method in Python
The standard string title()
method in Python is pretty naive and doesn't correctly handle converting even fairly simple words and phrases to title case (hyphenated words, phrases with quotes, phrases with prepositions, etc.).
In Googling around, I found a few solutions in different l开发者_开发知识库anguages to this problem. Can anyone recommend a good implementation of this in Python?
Found this via Google: http://muffinresearch.co.uk/archives/2008/05/27/titlecasepy-titlecase-in-python/
精彩评论