473,379 Members | 1,312 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,379 software developers and data experts.

Outputing Xml from ASPX

Hi. I want to write an .ASPX page that does nothing but returns a proper XML
document to the client (IE or whatever). If I have a fully composed
"XmlDocument" object in my .ASPX file's Page_Load() and I want to output the
Xml in that object and have to xml document returned have the proper header
info, etc. so that it will be received as XML, how do I do this. I'm sure
it's incredibly simple but I haven't worked it out.

Thanks
Nov 18 '05 #1
2 905


"Alex Maghen" wrote:
Hi. I want to write an .ASPX page that does nothing but returns a proper XML
document to the client (IE or whatever). If I have a fully composed
"XmlDocument" object in my .ASPX file's Page_Load() and I want to output the
Xml in that object and have to xml document returned have the proper header
info, etc. so that it will be received as XML, how do I do this. I'm sure
it's incredibly simple but I haven't worked it out.

Thanks

Nov 18 '05 #2
Hi Alex,
If you are trying to ouptput the XML as it is in your browser, then try to
use the following line of code in your .ASPX page...

<META http-equiv="Content-Type" content="text/xml">

Good luck,
K.V.Ravindra Kumar

"Alex Maghen" wrote:
Hi. I want to write an .ASPX page that does nothing but returns a proper XML
document to the client (IE or whatever). If I have a fully composed
"XmlDocument" object in my .ASPX file's Page_Load() and I want to output the
Xml in that object and have to xml document returned have the proper header
info, etc. so that it will be received as XML, how do I do this. I'm sure
it's incredibly simple but I haven't worked it out.

Thanks

Nov 18 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: bissatch | last post by:
Hi, I have the following XML content in a file (main.xml): <?xml version="1.0" encoding="iso-8859-1"?> <menu> <option title="Home" href="home.php"> <option title="News" href="news.php">...
2
by: Antonio Ooi | last post by:
Hi, Probably due to my 'Language for non-Unicode Setting' in Regional Settings, my ASP page keeps outputing the date format as Chinese Simplified characters when issuing say, <%=Now()%>. In...
0
by: Michael Mitchell via DotNetMonster.com | last post by:
* I need to collect the input data on example1.aspx by hitting the review button. * Out put the data in the corresponding Labels on Example2.aspx. * Save Example2.aspx to a File of the users choice...
10
by: ptass | last post by:
Hi In asp.net 2.0 an aspx files .cs file is a partial class and all works fine, however, I thought I’d be able to create another class file, call it a partial class and have that compile and...
3
by: premier | last post by:
I have a web page that's taking in data from text boxes, drawing a chart to represent the data, and then outputting the chart in PNG format. What I cant figure out how to do, is to output the...
24
by: John Rivers | last post by:
ASPX which means ASPX pages, the code-behind concept, User Controls, Web Controls etc. is very poorly designed and makes it extremely hard to develop professional quality web applications. ASPX...
4
by: jdcrief | last post by:
Using Visual C++2005 Expression Edition Having trouble outputting the value referenced by the pointer and then outputing the address of the pointer for the char. Any ideas would be greatly...
8
by: Jon Slaughter | last post by:
can one "stream" image data to a browser? I created an image using gd and when I do imagepng I just get the binary data for the image written as text instead of the image itself. Now I'm...
9
by: flin2k | last post by:
I'm using XSLT to process an inbound xml file and wanted to translate all the ® to &reg; but it's not allowing me to put in a & symbol. When I use &amp;reg; it's outputing &amp;reg. How can I get the...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.