Forum Moderators: coopster
<?xml version="1.0"?>
<?xml:stylesheet type="text/xsl" href="style.xsl"?>
<index>
<pageTitle>Ryan's Favorite Sites</pageTitle>
<header>
<text>Ryan's Favorites</text>
<version>1.0.1</version>
</header>
<main>
<site><name>example.com</name>
<desc>The greatest site for aviation in the world!</desc>
<addy>http://www.example.com</addy>
<dtad>2004-06-13 09:48:16</dtad>
</site>
<site>
<name>Yahoo!</name><desc>Yahoo is probably one of the best websites out there.</desc>
<addy>http://www.yahoo.com</addy>
<dtad>2004-06-13 10:07:37</dtad>
</site>
<site>
<name>Python.org</name>
<desc>Find out about the wonderful language of Python!</desc><addy>http://www.python.org</addy>
<dtad>2004-06-13 19:48:11</dtad>
</site>
</main>
<footer>
<copyright>Ryan Kaskel</copyright>
<year>2004</year></footer>
</index>
[edited by: jatar_k at 5:06 am (utc) on June 14, 2004]
[edit reason] removed url added actual source [/edit]
If the URL is to the XML document, I would expect the PHP, if installed and working ok, to be processed before the XML/XSLT.
IE is the only browser I know, that will work the XSLT linked to an XML file it's opened.
I can't see in the edited post what the PHP is. Obviously, XML isn't XHTML so you don't want <!DOCTYPE HTML headers you only need the <?xml version="1.0"?>
<?php
header("Content-type: text/xml"); echo "<?xml version=\"1.0\"?> \n";
echo "<?xml-stylesheet type=\"text/xsl\" href=\"style.xsl\"?>";
.
.
.more code
.
.
?>