I have some very simple XML:
<properties>
<property>
<name>BobFish</name>
<explaination>Bob is a fish.</explaination>
</property>
<property>
<name>DaveFish</name>
<explaination>Dave is a fish.</explaination>
</property>
I want to query if from ASP. Something like:
Response.Write (GetExplaination("BobFish"))
This is the function I have so far:
Function GetExplaination(strXMLFile, strName)
'Declare local variables
Dim objXML
Dim objNode
set objXML = Server.CreateObject("Microsoft.XMLDOM")
objXML.load(strXMLFile)
Set objNode = objXML.SelectSingleNode("properties/property[name='" & strName & "']")
GetExplaination = "Nothing Yet"
End Function
So I have objNode containing the data I need. How do I extract the "Explaination" field from this?