I have a form which POST’s its data via AJAX:
$.ajax({
type: "POST",
url: "http://example.com/prp/resources/upscalc.php",
data: dataString,
success: function(data){
res=data;
alert (res);return false;
}
});
And what is being outputted to the page is currently this:

What do I need to do so the only value I alert out is the number(in this case $66.52) at the end of the alert?
P.s. additional information, the xml at the top is from a UPS api call, and I cannot get rid of it.
Many thanks!
How about –
Edit: Thanks to David for the idea that “–>” could potentially exist in the UPS response, and it’s safer to lop off the last element of the array rather than the second