Skip to main content

Encode HTML

Anatomy

<encode:html var="var">
string
</encode:html>

Description: ENCODE:HTML encodes a value by converting special reserved characters to their applicable HTML entites and whitespace characters to a meaningful HTML representation.

ENCODE:HTML is compatible to the DECODE:HTML operation, but not the complement thereof.

Attention:

The characters mentioned above have special significance in HTML, and should be represented by HTML entities if they are to preserve their meanings.

Attributes

NameTypeDescriptionDefined By
varvarResult variable name encode:html

Results:

BindingTypePredicate
varstringN/A

Examples

Example

<output>
<encode:html>Hello World!&n;My name is "iXML" &amp; I am a XML derivative!</encode:html>
</output>

<!-- Hello World!<br />My name is &quot;iXML&quot; &amp; I am a XML derivative! -->