Deserializes a string in XML format to a ColdFusion object.

deserializeXML( String strToDeserialize, boolean useCustomSerializer ); → returns any

This function requires Adobe ColdFusion 11 and up. Not supported on Lucee, OpenBD, etc.

deserializeXML Argument Reference


A string that needs to be deserialized.


Boolean. Whether to use the custom serializer or not. The default value is true. The custom serializer will be always used for XML deserialization. If false, the XML/JSON deserialization will be done using the default ColdFusion behavior. If any other type is passed with useCustomSerializer as false, then TypeNotSupportedException will be thrown.

Examples sample code invoking the deserializeXML function

<cfset value = deserializeXML(toString(xmlDoc.root.XMLChildren[i].XMLChildren[1]), true)> 

Fork me on GitHub