XML : XML parsing "not well-formed"

I received in the console a lot of not well-formed with :

  language="en";  $.ajax({      url: 'translate.xml',      dataType: "xml",      success: function(xml) {          $(xml).find('translation').each(function(){              var id = $(this).attr('id');              var text = $(this).find(language).text();              $("." + id).append(text);          });      }  });    

My XML file "translate.xml" have this format :

  <?xml version="1.0" encoding="UTF-8"?>  <translations>  <translation id="t_house">      <en>house</en>      <fr>maison</fr>  </translation>  <translation id="t_boat">      <en>boat</en>      <fr>bateau</fr>  </translation>  </translations>    

I don't understand where these warnings come from ?

No comments:

Post a Comment