  make_list = stringfilter(make_list)
  
  def slugify(value):
      """
      Normalizes string, converts to lowercase, removes non-alpha chars and
      converts spaces to hyphens.
      """
      import unicodedata
      value = unicodedata.normalize('NFKD', value).encode('ascii', 'ignore')
      value = unicode(re.sub('[^\w\s-]', '', value).strip().lower())
      return re.sub('[-\s]+', '-', value)
 
</s> remove     Returns the value turned into a list. For an integer, it's a list of
    digits. For a string, it's a list of characters.
 </s> add     Returns the value turned into a list.

    For an integer, it's a list of digits.
    For a string, it's a list of characters. </s> remove     "Takes a phone number and converts it in to its numerical equivalent"
 </s> add     """Takes a phone number and converts it in to its numerical equivalent.""" </s> remove         except TypeError: # len() of unsized object
 </s> add         except TypeError: # len() of unsized object. </s> remove     "Replaces ampersands with ``&amp;`` entities"
 </s> add     """Replaces ampersands with ``&amp;`` entities.""" </s> remove     "Formats a time according to the given format"
 </s> add     """Formats a time according to the given format."""
    Normalizes string, converts to lowercase, removes non-alpha characters,
    and converts spaces to hyphens.
  make_list = stringfilter(make_list)
  
  def slugify(value):
      """
    Normalizes string, converts to lowercase, removes non-alpha characters,
    and converts spaces to hyphens.
    Normalizes string, converts to lowercase, removes non-alpha characters,
    and converts spaces to hyphens.
      """
      import unicodedata
      value = unicodedata.normalize('NFKD', value).encode('ascii', 'ignore')
      value = unicode(re.sub('[^\w\s-]', '', value).strip().lower())
      return re.sub('[-\s]+', '-', value)
keep keep keep keep replace replace keep keep keep keep keep
 Style and import fixes.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6641 bcc190cf-cafb-0310-a4f2-bffc1f526a37 
django/template/defaultfilters.py