setSkin() public method

Sets the skin.
public setSkin ( $skin )
$skin
Esempio n. 1
0
require_once WEBROOT . 'includes/autoconf.php';
$kga = new Kimai_Config(array('server_prefix' => $server_prefix, 'server_hostname' => $server_hostname, 'server_database' => $server_database, 'server_username' => $server_username, 'server_password' => $server_password, 'server_charset' => $server_charset, 'defaultTimezone' => $defaultTimezone, 'password_salt' => isset($password_salt) ? $password_salt : ''));
// will inject the version variables into the Kimai_Config object
include WEBROOT . 'includes/version.php';
// write vars from autoconf.php into kga
if (isset($language)) {
    $kga->setLanguage($language);
}
if (isset($authenticator)) {
    $kga->setAuthenticator($authenticator);
}
if (isset($billable)) {
    $kga->setBillable($billable);
}
if (isset($skin)) {
    $kga->setSkin($skin);
}
date_default_timezone_set($defaultTimezone);
Kimai_Registry::setConfig($kga);
// ============ global namespace cleanup ============
// remove some variables from the global namespace, that should either be
// not accessible or which are available through the kga config object
$cleanup = array('server_prefix', 'server_hostname', 'server_database', 'server_username', 'server_password', 'server_charset', 'language', 'password_salt', 'authenticator', 'defaultTimezone', 'billable', 'skin');
foreach ($cleanup as $varName) {
    if (isset(${$varName})) {
        unset(${$varName});
    }
}
unset($cleanup);
// ============ setup database ============
// we do not unset the $database variable