I'm running a SharePoint method with SPServices that should copy several items. I just noticed that the return value is "Success" even when I've specified an invalid location and nothing has actually happened. Since I can't use status, I noticed that the xdata.responsetext returns this:
<Results><CopyResult ErrorCode="Unknown" ErrorMessage="Object reference not set to an instance of an object." DestinationUrl="[someurlhere]" /></Results></CopyIntoItemsResponse>
I tried returning xdata.responseText.find("Results").text(); and was going to write a condition to see if it contains "ErrorMessage" (since I don't get this tag at all on valid destinations), but this doesn't return anything even though I'm able to return things like the 0 in
"<CopyIntoItemsResult>0</CopyIntoItemsResult>". Is there an alternative method? I'm relatively new to jquery, so I'm hoping I'm making a novice mistake.
FYI: The reason I'm using responseText instead of responseXML is because of an issue with jquery 1.9 where the xml is undefined with spservices calls by the way.