Url Encoding
Closed this issue · 3 comments
jackdotink commented
I'm opening this specifically for emoji url encoding for discord, but url encoding has many usecases. Just a nice feature to have.
ccuser44 commented
You can easily make this with string.gsub
filiptibell commented
You can easily make this with
string.gsub
The percent-encoding spec for urls is not that trivial to implement. If you only need to encode things like certain ascii characters and spaces, string.gsub
or one of the other string manipulation functions is probably fine, but if you want to support different character sets, emojis, or raw bytes it gets a lot trickier (and slower).
filiptibell commented
net.urlEncode
and net.urlDecode
have been added for the upcoming version 0.6.0