I have been having issues with parsing some XML. I have no control over the structure of the XML I receive.
<response>
<variable name = "variable_name">variable value</variable>
<variable name = "variable_name">variable value</variable>
</response>
I need to get the variable_name and value and write them to the webpage. However the number of of variables is dynamic.
I have already created functions for parsing different xml responses but the structure I receive is different for these.
How can I adapt the following code for the response?
function parseSystem(xml){
ControllerFound = true;
$(xml).find("response").each(function()
{
$("#ProjectName").append($(this).find("projectName").text());
});
Cheers
Mike