diff options
author | Christian Hesse <mail@eworm.de> | 2019-03-20 22:42:16 +0100 |
---|---|---|
committer | Christian Hesse <mail@eworm.de> | 2019-03-20 22:42:16 +0100 |
commit | 72d7050423ff6a518fbedd2f6c41377f125a25e5 (patch) | |
tree | 0f4c2c4dd24debbabee1874520969fc00f7781db /global-functions | |
parent | 213d326ad46dd115c3e6eaf673c4d384d89ec3c3 (diff) |
global-functions: encode all non-alphanumeric characters
Diffstat (limited to 'global-functions')
-rw-r--r-- | global-functions | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/global-functions b/global-functions index d6b2d4b..043da42 100644 --- a/global-functions +++ b/global-functions @@ -18,8 +18,11 @@ :local Return ""; :if ([ :len $Input ] > 0) do={ - :local Chars " %&"; - :local Subs { "%20"; "%25"; "%26" }; + :local Chars " !\"#\$%&'()*+,-./:;<=>\?@[\\]^_`{|}~"; + :local Subs { "%20"; "%21"; "%22"; "%23"; "%24"; "%25"; "%26"; "%27"; "%28"; "%29"; + "%2A"; "%2B"; "%2C"; "%2D"; "%2E"; "%2F"; "%3A"; "%3B"; "%3C"; "%3D"; + "%3E"; "%3F"; "%40"; "%5B"; "%5C"; "%5D"; "%5E"; "%5F"; "%60"; "%7B"; + "%7C"; "%7D"; "%7E" }; :for I from=0 to=([ :len $Input ] - 1) do={ :local Char [ :pick $Input $I ]; |