rss calışmıyor
<?include ("dbs.php");
header("Content-type: text/xml");
function Temizlik($q) {
$q = str_replace("&","&",$q);
$q = str_replace(">",">",$q);
$q = str_replace("<","<",$q);
$q=trim($q);
return $q;
}
echo "<?xml version=\"1.0\" encoding=\"ISO-8859-9\"?><rss version=\"2.0\"><channel><title>$site_adi</title><description>$slogan</description><link>$site</link><language>tr-TR</language>";
$i = $_GET['i'];
$id = $_GET['id'];
if ($i == "h") {
$sql = "Select * from program order by hit desc limit 0,10";
}
if ($i == "d") {
$sql = "Select * from program order by tarih desc limit 0,10";
}
if ($i == "t") {
$sql = "Select * from program where dil = 'Türkçe' order by tarih desc limit 0,10";
}
if ($i == "y") {
$sql = "Select * from program where dil = 'İngilizce' order by tarih desc limit 0,10";
}
if ($i == "k") {
$sql = "Select * from program where kategori = '$id' order by tarih desc limit 0,10";
}
if ($i == "ak") {
$sql = "Select * from program where altkat = '$id' order by tarih desc limit 0,10";
}
$q=mysql_query($sql);
while ($r=mysql_fetch_array($q)) {
?>
<item>
<title><? echo $r[isim]; ?></title>
<link><? echo $site; ?>/Program/<? echo $r[adi_s]; ?>.html</link>
<description><? echo Temizlik($r[aciklama]); ?></description>
</item><?}?>
</channel>
</rss><?@mysql_close();?>