Hello all im trying to take a returned xml file that the body looks like this
Im trying to split this data using javascript and then append the data as individual Child Elements of String. Im able to create an array using .split and i get no errors on my update statements but when i alert the text it still gives me the <br/>'s heres my function any help is greatly appreciated
Thanks in advance
MCP, .Net Solutions Development <%_%>
Code:
<string xmlns="[URL unfurl="true"]http://microsoft.com/webservices/">Entry[/URL] 1<br/> Entry2<br/>
</string>
Im trying to split this data using javascript and then append the data as individual Child Elements of String. Im able to create an array using .split and i get no errors on my update statements but when i alert the text it still gives me the <br/>'s heres my function any help is greatly appreciated
Code:
function placeHint3(xmlresponse){
var xmlDom = new ActiveXObject("Microsoft.XMLDOM")
xmlDom.async = false
xmlDom.setProperty("SelectionNamespaces", "xmlns:ph='[URL unfurl="true"]http://microsoft.com/webservices/'");[/URL]
xmlDom.setProperty("SelectionLanguage", "XPath");
xmlDom.load(xmlresponse)
var xmlSplit= xmlDom.text.split('<br/>')
//This runs through w/o error but i have a feeling
// its never happening
//anyone know a better way to do this and erase
//the current text with a blank
for (var i=0; i < xmlSplit.Length; i++){
var CreateElement = xmlDom.createElement('ph:client'+i)
CreateElement.setValue(xmlSplit(i));
CreateElement.append
}
//SelectNode = xmlDom.selectSingleNode('client2')
alert(xmlDom.text)
traverse(xmlDom)
}
Thanks in advance
MCP, .Net Solutions Development <%_%>