diff --git a/themes/blueprint/js/hierarchyTree_JSTree.js b/themes/blueprint/js/hierarchyTree_JSTree.js index f9cb51b9ab3a6674914d615c630aa502f4d74633..c5cf88e1d28e385028fa327a61a8f1913cec34cc 100644 --- a/themes/blueprint/js/hierarchyTree_JSTree.js +++ b/themes/blueprint/js/hierarchyTree_JSTree.js @@ -62,7 +62,7 @@ $(document).ready(function() { "url" : path + '/Hierarchy/GetTree?' + $.param({'hierarchyID': hierarchyID, 'id': recordID, 'context': context, mode: "Tree"}), success: function(data) { // Necessary as data is a string - var dataAsXML = parseXml(data); + var dataAsXML = $.parseXML(data); if(dataAsXML) { var error = $(dataAsXML).find("error"); if (error.length > 0) { @@ -90,25 +90,6 @@ $(document).ready(function() { }); }); -// Parse XML (Feature not available in JQuery 1.4) -if (typeof window.DOMParser != "undefined") { - parseXml = function(xmlStr) { - return ( new window.DOMParser() ).parseFromString(xmlStr, "text/xml"); - }; -} else if (typeof window.ActiveXObject != "undefined" && - new window.ActiveXObject("Microsoft.XMLDOM")) { - parseXml = function(xmlStr) { - var xmlDoc = new window.ActiveXObject("Microsoft.XMLDOM"); - xmlDoc.async = "false"; - xmlDoc.loadXML(xmlStr); - return xmlDoc; - }; -} else { - parseXml = function(xmlStr) { - return false; - }; -} - function showTreeError(msg) { $("#hierarchyTreeHolder").html('<p class="error">' + msg + '</p>'); }