Dim h As HTMLSanitize
' Can initialize with BLOCKS, FORMATTING, IMAGES, LINKS, STYLES, TABLES or blank
h.Initialize("FORMATTING") ' will leave formatting intact
Log(h.Sanitize("<script>function naughtyStuff(){}</script><b>Hello</b><a href='https://example.com'>",False))
h.Initialize("LINKS") ' will leave links intact
Log(h.Sanitize("<script>function naughtyStuff(){}</script><b>Hello</b><a href='https://example.com'>",False))
h.Initialize("") ' will only leave standard Url protocols intact (eg redirect URL's for OAuth)
Log(h.Sanitize("<script>function naughtyStuff(){}</script>f=json&token=XYZ",False))
Log(h.Sanitize("<script>function naughtyStuff(){}</script>f=json&token=XYZ",True))
Log(h.DecodeHtml("f=json&token=XYZ"))