1 Reply Latest reply on Aug 14, 2009 4:41 PM by alexManuelSilva

    load as xml


      I am trying to load a piece of html code as  xml from a given url but since one of the tags (meta) hasn´t been closed, my URLLoader is not able to load  it as xml. Is there any way of working around this problem?

      Sofar, all I have been able to do was to load it as a String and slice it in several points.


      Arrays don´t seem to work in this case.

      I tried, for example:


         var exp:String="blockquote"
         var exp_1:String="</p>";
         var ind:int=loader.data.indexOf(exp);
         var ind_1:int=loader.data.indexOf(exp_1,ind+1);


         var str:String=loader.data.slice(ind+exp.length+1,ind_1);

         var index:Array=str.toString.match("</ul>");


      and it returned an array of lenght 1 instead of 8;

      thanks for helping