<?
function icon_anketa($name,$code='path')
{
$name=preg_replace('#[^A-zА-яЁё0-9 _\-\.]#i', null, $name);
if (file_exists(H."a/icons/$name") && $name!=null)
{
$path= '/a/icons/'.$name.'';
}
else
{
$path= '/a/icons/default.png';
}
if ($code=='path')
return $path;
else
{
return "<img src='$path'  alt='' />";
}
}
?>