per adesso ho creato questo codice
Codice PHP:
<?php
header ("Content-type: text/xml");
echo "<?xml version='1.0' encoding='utf-8'?>";
echo "<photos>";
if ($handle = opendir('/membri/simoxz/sibgallery/albums/anconapub/')) {
while (false != ($file = readdir($handle))) {
echo " <photo desc='' url='http://simoxz.altervista.org/sibgallery/albums/anconapub/$file' />";
}
closedir($handle);
}
echo "</photos>";
?>
che mi restituisce un xml
Codice PHP:
<photos>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/oyb6ce8n.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/897cvbne.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/wv89e7y.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/8ncewew.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/crcfgs.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/."/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/u5cv7.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/ut6v77.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/.."/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/5wf4ww.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/vecsctw3.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/76vwn9.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/8rbwn9w.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/5y67uw8n9w.jpg"/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/yv7wnc87y.jpg"/>
</photos>
mi sapreste dire perchè ci sono questi due file di troppo
Codice PHP:
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/."/>
<photo desc="" url="http://simoxz.altervista.org/sibgallery/albums/anconapub/.."/>