Хранилища Subversion ant

Сравнить редакции

Учитывать пробелы Редакция 281 → Редакция 282

/trunk/admin.php
43,7 → 43,7
 
$header = "<div id='head'><div class='title'>".$core->getSetting('codename',$db)." Admin Panel</div><div class='smalltitle'>version: ".$core->getSetting('version',$db)."</div></div>";
 
$login = "<div id='login'>"._("You are logged as").": <b>admin</b> <a class='dashed' href='./signout.php' style='color:red;'>["._("exit")."]</a></div>";
$login = "<div id='login'>"._("You are logged as").": <b>".$login."</b> <a class='dashed' href='./signout.php' style='color:red;'>["._("exit")."]</a></div>";
 
 
$menu_title = array ( _("Management"), _("References"), _("Preferences") );
895,8 → 895,7
if (isset($_GET['chtheme'])){
$chtheme = $secure->wrapStr($_GET["chtheme"]);
$chicon = $secure->wrapStr($_GET["chicon"]);
$theme->SetTheme($chtheme,$db);
$theme->setIcon($chicon,$db);
$theme->setTheme($chtheme,$chicon,$db);
$display.='<p style="color:red;">Тема измененна</p>';
}
$themename = $theme->getThemeName($core,$db);
/trunk/lib/theme.php
46,7 → 46,7
}
function getThemeName($link,$dblink) { //TODO remove links
$result=$link->getSetting('theme',$dblink);
$result=$link->getSetting('style',$dblink);
if (!file_exists('./themes/styles/'.$result.'/style.css')) $result='default';
return $result;
}
55,11 → 55,9
if (!file_exists('./themes/icons/'.$result.'/edit.png')) $result='tango';
return $result;
}
function setTheme($newtheme,$dblink){
$req =& $dblink->query("UPDATE settings SET optvalue='$newtheme' WHERE opt='theme'");
function setTheme($theme,$icons,$dblink){
$req =& $dblink->query("UPDATE settings SET optvalue='$theme' WHERE opt='style'");
$req =& $dblink->query("UPDATE settings SET optvalue='$icons' WHERE opt='icons'");
}
function setIcon($newtheme,$dblink){
$req =& $dblink->query("UPDATE settings SET optvalue='$newtheme' WHERE opt='icons'");
}
}
?>