$file = simplexml_load_file("http://www.cbr.ru/scripts/XML_daily.asp?date_req=".date("d/m/Y"));
$xml = $file->xpath("//Valute[@ID='R01235']");
$valute = strval($xml[0]->Value);
$dollar = str_replace(",",".",$valute);
echo $dollar;
sg("kurs.dollar",$dollar);
$xml = $file->xpath("//Valute[@ID='R01239']");
$valute = strval($xml[0]->Value);
$euro = str_replace(",",".",$valute);
echo $euro;
sg("kurs.euro",$euro);
$xml = $file->xpath("//Valute[@ID='R01270']");
$valute = strval($xml[0]->Value);
$rupi = str_replace(",",".",$valute);
echo $rupi;
sg("kurs.rupi",$rupi);
$xml = $file->xpath("//Valute[@ID='R01700J']");
$valute = strval($xml[0]->Value);
$turk_lir = str_replace(",",".",$valute);
echo $turk_lir;
sg("kurs.turk_lir",$turk_lir);
$xml = $file->xpath("//Valute[@ID='R01375']");
$valute = strval($xml[0]->Value);
$china = str_replace(",",".",$valute);
echo $china;
sg("kurs.china",$china);