HTML-escape a string or object.
This converts any non-string objects passed into it to strings (actually, using unicode()). All values returned are non-unicode strings (using &#num; entities for all non-ASCII characters).
None is treated specially, and returns the empty string.
Convert an IRI portion to a URI portion suitable for inclusion in a URL.
(An IRI is an Internationalized Resource Identifier.)
This is the algorithm from section 3.1 of RFC 3987. However, since we are assuming input is either UTF-8 or unicode already, we can simplify things a little from the full method.
Returns an ASCII string containing the encoded result.
A MultiDict wrapper that decodes returned values to unicode on the fly.
Decoding is not applied to assigned values.
The key/value contents are assumed to be str/strs or str/FieldStorages (as is returned by the paste.request.parse() functions).
Can optionally also decode keys when the decode_keys argument is True.
FieldStorage instances are cloned, and the clone’s filename variable is decoded. Its name variable is decoded when decode_keys is enabled.
Return dict where values are single values or a list of values.
The value is a single value if key appears just once. It is a list of values when a key/value appears more than once in this dictionary. This is similar to the kind of dictionary often used to represent the variables in a web request.