Mysterious http://www.w3.org/2005/Atom

EDN Admin

Well-known member
Joined
Aug 7, 2010
Messages
12,794
Location
In the Machine
I have the requirement to add the following (xmlns:atom) to my xml document in the topmost element:
<feed xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:atom="http://www.w3.org/2005/Atom"
I accomplish this by using the XmlSerializerNamespaces as follows:

XmlSerializerNamespaces ns = new XmlSerializerNamespaces();
ns.Add("atom", "http://www.w3.org/2005/Atom");

This works great, but for some odd reason it is also adding the following at the tail end of the document which is breaking the xsd validation:

<atom:link>http://www.w3.org/2005/Atom</atom:link>
</feed>


Question is, how do I prevent this from appearing or what is the best way to remove it? Ive tried to search for this node and replace it with no success, but the ideal solution would be to just prevent it in the first place. The xml document
that is generated is large (>100MB) so this task needs to take performance into consideration.

Thank You
<br/>
<br/>

View the full article
 
Back
Top