1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35
| <?php
mysql_connect('localhost', 'root', '');
mysql_select_db('oddo');
$result = mysql_query('select * from oddo_xml where id=1');
$row = mysql_fetch_array($result);
header("Content-Type: text/xml; charset=ISO-8859-1");
echo "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>
<playlist version=\"1\" xmlns=\"http://xspf.org/ns/0/\">
<trackList>
<track>
<annotation>".$row['annotation']."</annotation>
<location>".$row['location']."</location>
<info>".$row['info']."</info>
<image>".$row['image']."</image>
</track>
</trackList>
</playlist>";
?> |