myURLDecode

Decode a URL, opposite of Server.URLEncode

Function myURLDecode(strString)
 Rett      = Replace(strString, "%2F", "/")
 Rett       = Replace(Rett, "%7C", "|")
 Rett       = Replace(Rett, "%3F", "?")
 Rett       = Replace(Rett, "%21", "!")
 Rett       = Replace(Rett, "%40", "@")
 Rett       = Replace(Rett, "%5C", "\")
 Rett       = Replace(Rett, "%23", "#")
 Rett       = Replace(Rett, "%24", "$")
 Rett       = Replace(Rett, "%5E", "^")
 Rett       = Replace(Rett, "%26", "&")
 Rett       = Replace(Rett, "%25", "%")
 Rett       = Replace(Rett, "%2A", "*")
 Rett       = Replace(Rett, "%28", "(")
 Rett       = Replace(Rett, "%29", ")")
 Rett       = Replace(Rett, "%7D", "}")
 Rett       = Replace(Rett, "%3A", ":")
 Rett       = Replace(Rett, "%2C", ",")
 Rett       = Replace(Rett, "%7B", "{")
 Rett       = Replace(Rett, "%2B", "+")
 Rett       = Replace(Rett, "%2E", ".")
 Rett       = Replace(Rett, "%2D", "-")
 Rett       = Replace(Rett, "%7E", "~")
 Rett       = Replace(Rett, "%2D", "-")
 Rett       = Replace(Rett, "%5B", "[")
 Rett       = Replace(Rett, "%5F", "_")
 Rett       = Replace(Rett, "%5D", "]")
 Rett       = Replace(Rett, "%60", "`")
 Rett       = Replace(Rett, "%3D", "=")
 Rett       = Replace(Rett, "%27", "'")
 Rett       = Replace(Rett, "+", " ")
 Rett       = Replace(Rett, "%22", Chr(34))
 myURLDecode    = Rett
End Function

strString

Views 520 Downloads 160

'encode', 'decode', 'URLEncode', 'Server', 'convert', 'replace', 'change', 'urldecode', 'string', 'NotMyWork'

ANmarAmdeen
324
Texts + Strings Classic ASP
Revisions

v2.0