I want to let users in my Facebook application post YouTube videos.
Any user can put a YouTube link in an input text box. The behavior identical to posting a video on their Facebook wall.
The application extracts the video id from the link and creates a different YouTube link.

For example, if the link is: <http://www.youtube.com/watch?v=JBWd_yJPbr8&feature=related>   
The id is: `JBWd_yJPbr8` and the request becomes http://gdata.youtube.com/feeds/api/videos/JBWd\_yJPbr8

The problem is to parse the returned XML. This is not standard XML, or at least I have not gotten it to work using standard XML parsers. How can i parse this XML? I need a thumbnail, title and description...

```
using (XmlReader reader = XmlReader.Create(new StringReader(xmlString)))
{
    XmlWriterSettings ws = new XmlWriterSettings();
    ws.Indent = true;
    using (XmlWriter writer = XmlWriter.Create(output, ws))
    {

            while (reader.Read())
            {
                switch (reader.NodeType)
                {
                    case XmlNodeType.Element:
                        writer.WriteStartElement(reader.Name);
                        break;
                    case XmlNodeType.Text:
                        writer.WriteString(reader.Value);
                        break;
                    case XmlNodeType.XmlDeclaration:
                    case XmlNodeType.ProcessingInstruction:
                        writer.WriteProcessingInstruction(reader.Name, reader.Value);
                        break;
                    case XmlNodeType.Comment:
                        writer.WriteComment(reader.Value);
                        break;
                    case XmlNodeType.EndElement:
                        writer.WriteFullEndElement();
                        break;
                }
            }

        }
    }

```

Tis case is throw exception : 

```
case XmlNodeType.Element:
writer.WriteStartElement(reader.Name);

```

Element type not valid