if(($content = file_get_contents("http://www.tcmb.gov.tr/kurlar/today.xml")))
{
fwrite(fopen("today.xml",w),$content);
}
else
{
$content=file_get_contents("today.xml");
}

?