(string)
| 49 | return urllib.quote(string, safe="~") |
| 50 | |
| 51 | def utf8(string): |
| 52 | return isinstance(string, unicode) and string.encode("utf-8") or str(string) |
| 53 | |
| 54 | def normalize(string): |
| 55 | # Normalize accents (é => e) for services that have problems with utf-8 |