Encode web

Purpose: Web(HTML)-encode string.

 encode-web <string> to <encoded string> \
     [ input-length <length> ]

encode-web encodes <string> so it can be used in a HTML-like markup text (such as a web page or an XML/XHTML document), and stores the result in <encoded string>.

You can encode only the first <length> bytes, given by "input-length" clause.
Examples
In this example, a string "str" will be web-encoded and the result is in "result" variable:
 set-string str="  x<y>z&\"'  "
 encode-web str to result

The "result" is "   x&lt;y&gt;z&amp;&quot;&apos;  ".
See also
Web encoding
decode-web  
encode-web  
See all
documentation


Copyright (c) 2019-2024 Gliim LLC. All contents on this web site is "AS IS" without warranties or guarantees of any kind.