String XmlEncode Example
Demonstrates the xml encoding of string input
Smartsite SXML | Copy Code |
---|---|
<se:buffer name="data"> <b>this text contains ' and " quotes</b> </se:buffer> Default xml encode: {string.xmlencode($data)} Xml encode without quotes: {string.xmlencode($data, false)} Custom xml encode: {string.xmlencode($data, 'ampersand,quotationmark')} |
Example Result | Copy Code |
---|---|
Default xml encode: <b>this text contains ' and " quotes</b> Xml encode without quotes: <b>this text contains ' and " quotes</b> Custom xml encode: <b>this text contains ' and " quotes</b> |