Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > ASP .Net > XML in an .ahsx file

Reply
Thread Tools

XML in an .ahsx file

 
 
Lloyd Dupont
Guest
Posts: n/a
 
      12-06-2005
I'm using a newsgroup/blog/mailing list/forums all in one provider.
After some negociation they would let me display the web interface of my
newsgroup with a special template.

This special tempalet could be provided as a dynamic XML file.

I'm thinking of using a ".ashx" to generate it, is it a good choice?
Anyway .ashx begine with a 'context.Response.ContentType = "my xml mime
type"'
so.. whatis the XML mimetype?
I'm thinking of using "text/xml" what do you think of that?


 
Reply With Quote
 
 
 
 
Andrew Robinson
Guest
Posts: n/a
 
      12-06-2005
I think using an ASHX file works well:

context.Response.ClearContent();

context.Response.ContentType = "application/rss+xml";

XmlTextWriter xmlTextWriter = new
XmlTextWriter(context.Response.OutputStream, System.Text.Encoding.UTF;

xmlTextWriter.Formatting = Formatting.Indented;

xmlTextWriter.WriteStartDocument();

xmlTextWriter.WriteComment("Generated with my xml / rss writer v1.0b");

xmlTextWriter.WriteStartElement("rss");

xmlTextWriter.WriteAttributeString("version", "2.0");

{

xmlTextWriter.WriteStartElement("channel");

{

xmlTextWriter.WriteStartElement("title");


--

Andrew Robinson
www.binaryocean.com
www.bellinghamdotnet.org


"Lloyd Dupont" <net.galador@ld> wrote in message
news:ORrglFr%(E-Mail Removed)...
> I'm using a newsgroup/blog/mailing list/forums all in one provider.
> After some negociation they would let me display the web interface of my
> newsgroup with a special template.
>
> This special tempalet could be provided as a dynamic XML file.
>
> I'm thinking of using a ".ashx" to generate it, is it a good choice?
> Anyway .ashx begine with a 'context.Response.ContentType = "my xml mime
> type"'
> so.. whatis the XML mimetype?
> I'm thinking of using "text/xml" what do you think of that?
>



 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
including one XML file in another XML file Johan XML 20 02-27-2007 04:29 PM
Problem to insert an XML-element by XSLT-converting from one XML-file into another XML-file jkflens XML 2 05-30-2006 09:41 AM
Different results parsing a XML file with XML::Simple (XML::Sax vs. XML::Parser) Erik Wasser Perl Misc 5 03-05-2006 10:09 PM
UPnP xml file to WSDL xml file Robert S XML 1 10-14-2005 09:32 PM
tool to validate xml file against custom XML Schema file Leona XML 9 11-01-2004 09:51 AM



Advertisments