public void getImgs(string _html) { Regex rxImages = new Regex("<img.+?src=[\"'](.+?)[\"'].+?>", RegexOptions.IgnoreCase & RegexOptions.IgnorePatternWhitespace); MatchCollection mc = rxImages.Matches(_html); foreach(Match m in mc) { Console.WriteLine(m.Groups[0].Value); Console.WriteLine(m.Groups[1].Value); } } result: 0: < img src = "http://yeonpil.org/소녀시대.jpg" / > 1: http: //yeonpil.org/소녀시대.jpg
댓글 없음:
댓글 쓰기