I need to replace the source of some <img>
in a HTML formatted string, but after I extract the URLs they don't match with the original string. This simple code should work, but it doesn't:
var str1:String = "<img src=\"file:///D:\\boo\\hoo\\hoo\\pic.jpg\">";
var str2:String = "file:///D:\\boo\\hoo\\hoo\\pic.jpg";
var i:int = str1.search(str2);
There is no match with src1.split(src2)
either. I must be doing something wrong, but I can't figure out what.