Yet (another urlencode compatible) encoding scheme
yencode(string, escape = "%", whitelist = c("._~-", "][!$&'()*+,;=:/?@#"))yencoder(escape = "%", whitelist = c("._~-", "][!$&'()*+,;=:/?@#"))
ydecode(string, escape = "%")
ydecoder(escape = "%")
The processed (encoded or decoded) string.
The string to process.
The escape character to use.
Any characters that should not be escaped. See details.
Letters and digits are never escaped. Other characters are escaped unless
they appear in whitelist, which may include multi-byte characters. The
escape character is removed from the whitelist, with a warning, if present,
and must itself be a single ASCII character.
yencode() escapes the UTF-8 representation of string, whatever its
declared encoding, so the same text always gives the same result.
ydecode() returns strings marked as UTF-8, and raises an error if an
escape sequence is malformed or the decoded bytes are not valid UTF-8.