Quantcast
Channel: Web API
Viewing all articles
Browse latest Browse all 4850

Tell XmlFormatter to include processing information

$
0
0

I am using Web API 2 to return some data serialized as XML using the XML MediaTypeFormatter.  Is there any way for me to attach processing instructions to the response such as an xml-stylesheet directive?  Right now when the client receives the data it is raw XML and not an XML document.  I have tried setting UseXmlSerializer but it seems that only the DocumentElement is serialized- and that omits the processing instructions. 


Viewing all articles
Browse latest Browse all 4850

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>