The current Css is modified if a specific cookie is set. re #25

This commit is contained in:
Sébastien Lucas 2013-05-29 21:13:02 +02:00
parent 530f5b6291
commit f5ff23cf9d

View file

@ -17,8 +17,19 @@ function getURLParam ($name, $default = NULL) {
return $default;
}
function getCurrentOption ($option) {
global $config;
if (isset($_COOKIE[$option])) {
return $_COOKIE[$option];
}
if ($option == "style") {
return "default";
}
return $config ["cops_" . $option];
}
function getCurrentCss () {
return "styles/style-default.css";
return "styles/style-" . getCurrentOption ("style") . ".css";
}
function getUrlWithVersion ($url) {