<?php
header("Content-Type: text/xml; charset=UTF-8");
echo "<?xml version=\"1.0\" encoding=\"UTF-8\"?><urlset xmlns=\"http://www.sitemaps.org/schemas/sitemap/0.9\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xsi:schemaLocation=\"http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd\">";
echo "<url><loc>https://www.ratondebiblioteca.es/index.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Quienes%20somos.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Nuestro%20libros%20y%20musica.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista1-1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista1-2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista1-3.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista1-4.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista2-1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista2-2.php</loc><priority>0.5</priority><changefreq>always</changefreq></></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista2-3.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Revista3.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Librodevisitas.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRelatos.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRelatos1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRelatos2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasPoemas.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasPoemas1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasPoemas2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasLibros.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasLibros1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasLibros2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasSonido%20y%20cine.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasSonido%20y%20cine1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasSonido%20y%20cine2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasEntrevistas.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasEntrevistas1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasEntrevistas2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRevista.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRevista1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasRevista2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasNoticias.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasNoticias1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasNoticias2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasVisiones.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasVisiones1.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/LibrodevisitasVisiones2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Nuestros%20premios.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Agenda.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Miembros.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Red%20Social.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Ficha%20modelo.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Ficha%20modelo2.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Legalidad.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Taquilla.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Amigos.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/AnunciosPorPalabras.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Musica.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/CompartirRed.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
echo "<url><loc>https://www.ratondebiblioteca.es/Arte.php</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
$bd_host = "XXX";
$bd_usuario = "XXX";
$bd_password = 'XXX';
$bd_base = "XXX";
$con = mysql_connect($bd_host, $bd_usuario, $bd_password) or die();
mysql_select_db($bd_base, $con);
$sql = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Relatos'");
$sql1 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Poemas'");
$sql2 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Recomendamos'");
$sql3 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Sonido y cine'");
$sql4 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Entrevistas'");
$sql5 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Noticias' AND Subseccion='L'");
$sql6 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Noticias' AND Subseccion='M'");
$sql7 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Noticias' AND Subseccion='C'");
$sql8 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Noticias' AND Subseccion='F'");
$sql9 = sprintf("SELECT DISTINCT Direccion FROM Entradas WHERE Seccion='Noticias' AND Subseccion='O'");
$totalEnt = mysql_query($sql, $con);
$totalEnt1 = mysql_query($sql1, $con);
$totalEnt2 = mysql_query($sql2, $con);
$totalEnt3 = mysql_query($sql3, $con);
$totalEnt4 = mysql_query($sql4, $con);
$totalEnt5 = mysql_query($sql5, $con);
$totalEnt6 = mysql_query($sql6, $con);
$totalEnt7 = mysql_query($sql7, $con);
$totalEnt8 = mysql_query($sql8, $con);
$totalEnt9 = mysql_query($sql9, $con);
$finalEnt = mysql_num_rows($totalEnt);
$finalEnt1 = mysql_num_rows($totalEnt1);
$finalEnt2 = mysql_num_rows($totalEnt2);
$finalEnt3 = mysql_num_rows($totalEnt3);
$finalEnt4 = mysql_num_rows($totalEnt4);
$finalEnt5 = mysql_num_rows($totalEnt5);
$finalEnt6 = mysql_num_rows($totalEnt6);
$finalEnt7 = mysql_num_rows($totalEnt7);
$finalEnt8 = mysql_num_rows($totalEnt8);
$finalEnt9 = mysql_num_rows($totalEnt9);
mysql_close($con);
if ($finalEnt > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt1 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt1)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt2 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt2)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt3 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt3)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt4 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt4)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt5 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt5)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt6 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt6)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt7 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt7)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt8 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt8)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
if ($finalEnt9 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt9)) {
echo "<url><loc>".$Entradas['Direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
$bd_host = "XXX";
$bd_usuario = "XXXX";
$bd_password = 'XXX';
$bd_base = "XXX";
$con = mysql_connect($bd_host, $bd_usuario, $bd_password) or die();
mysql_select_db($bd_base, $con);
$sql10 = sprintf("SELECT DISTINCT direccion FROM Entradas ORDER BY nick");
$totalEnt10 = mysql_query($sql10, $con);
$finalEnt10 = mysql_num_rows($totalEnt10);
mysql_close($con);
if ($finalEnt10 > 0) {
while ($Entradas = mysql_fetch_assoc($totalEnt10)) {
echo "<url><loc>".$Entradas['direccion']."</loc><priority>0.5</priority><changefreq>always</changefreq></url>";
}
}
echo "</urlset>";
?>