slugify(allow_unicode=False) [source]
Converts to ASCII if allow_unicode is False (default). Converts spaces to hyphens. Removes characters that aren’t alphanumerics, underscores, or hyphens. Converts to lowercase. Also strips leading and trailing whitespace.
For example:
slugify(value)
If value is "Joel is a slug", the output will be "joel-is-a-slug".
You can set the allow_unicode parameter to True, if you want to allow Unicode characters:
slugify(value, allow_unicode=True)
If value is "你