XDocument xDoc = XDocument.Load("http://www.nydailynews.com/cmlink/NYDN.Article.rss"); XNamespace media = XNamespace.Get("http://search.yahoo.com/mrss/"); var images = xDoc.Descendants(media+"content") .Where(m=>m.Attribute("type").Value=="image/jpeg") .Select(m=>m.Attribute("url").Value) .ToArray();
- EDIT -
var images = feeds.Items .SelectMany(i => i.ElementExtensions .Select(e => e.GetObject<XElement>().Attribute("url").Value) ) .ToArray();
source share