The only real difference between HTML and XML (besides the obvious 
standards and formats and such) is the MIME type, I believe. HTML has a 
"text/html" MIME type, while XML can have a whole bunch, depending on what 
the XML is supposed to do. (I.e. text/xml, application/xml, 
application/xml-dtd, etc.)

Try outputing the XML using "text/xml" as the MIME type by using

header("Content-type: text/xml");

at the beginning of your script. (Or at least as the first bit of output -- 
nothing should come before the headers.


Rodrigo Peres wrote:

> Hi list,
> I'm new to the xml world, and I need to create a page with data retrieved
> from my database using PHP. The process is the same of create an html
> page?? I mean I can use echo to output the xml tags and values?? Since
> this page will be dinamically generated what kind of headers I need to use
> to this page become an xml???
> I saw many docs in web but all about parse an xml, but not in how to build
> one.

PHP General Mailing List (
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]

Reply via email to