Skip to content

Instantly share code, notes, and snippets.

@mgroves
Created June 11, 2014 21:05
Show Gist options
  • Save mgroves/660a7787ec962ada4525 to your computer and use it in GitHub Desktop.
Save mgroves/660a7787ec962ada4525 to your computer and use it in GitHub Desktop.
<%
dim myXml 'assume that this is populate with an XML string
dim oXml
Set oXml = Server.CreateObject("MSXML2.DOMDocument.6.0") 'don't forget to use Set
oXml.LoadXML(myXml)
dim node
Set node = oXml.selectSingleNode("//@ShoeSize") 'don't forget to use Set
response.write "Shoe Size: " & node.text & "<br />" 'outputs: "Shoe Size: 13<br />"
Set node = oXml.selectSingleNode("//@City") 'don't forget to use Set
response.write "City: " & node.text & "<br />" 'outputs: "City: Funkytown, USA<br />"
%>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment