I am extracting data from an XML file and then using the jQuery.find () function to access that data. However, in Firefox (version 37.0.2), I get the following errors in the JavaScript console:
Error: Unable to run script because scripts are blocked internally.
Error: not well-formed
Source Code:
<datarecord><div><a id='sizzle1430853521804'></a><select id='sizzle1430853521804- ]' msallowcapture=''><option selected=''></option></select></
Everything still works fine, but does anyone know how I can get rid of this error, or is it a bug in Firefox?
Here is my code:
$.ajax({
url:"file.xml",
type:"GET",
dataType:"xml",
success:function(xml){
$(xml).find("field_id").each(function(){
}
}
});
The XML file has the following format, and I used the XML validator to make sure that it is in order:
<?xml version="1.0" encoding="utf-8"?>
<datarecord>
<field_id><TheIdValue>8</TheIdValue><TheDisplayValue>Joe Bloggs</TheDisplayValue></field_id>
etc...
</datarecord>
I could not find a solution. Any suggestions?
source
share