XhochY > Schoorbs
Schoorbs
 
Font size:      

Configuration

General

All configuration of Schoorbs is done in the file config.inc.php. If you have a new installation, this file doesn't exist, the best way is to copy it from config.inc.php-dist, an example configuration.

Attention:
Undocumented variables may have at the moment no effect, since some modules were deactivated during the Fork from MRBS, e.g. the LDAP authentication, or they are only used during development. The deactivated modules are not usable at the moment because they require a security review, but if you need one of these modules, you write a short message to the mailinglist, so that the developers know which modules require attention. If you stay in contact with them, then it is likely that the module will be ready in a short time period.

Database

The first paragraph in the configuration file of Schoorbs is considering the database connection. As already said in the chapter 'installation', you have at the moment the choice between MySQL and PostgreSQL. Altough there are two options for MySQL considering the database driver, PHP offers the interfaces mysqli which should be used for systems with PHP 5+ and MySQL 5+, and mysql which should be used an all older systems. For PostgreSQL users only the module pgsql is available. The name of the selected database driver should be set as the value of the variable $dbsys. The value of the variable $db_host should be set to the host on which your database server is running, in most cases localhost will be sufficent. The name of your database should be set in $db_database. Username and password go into the variables $db_login and $db_password. The value of $db_tbl_prefix should correspond to the database prefix you have choosen during the installation.

Example configuration (connection via MySQLi):

$dbsys = "mysqli";
$db_host = "localhost";
$db_database = "schoorbs";
$db_login = 'schoorbs';
$db_password = 'secret_password';
$db_tbl_prefix = "schoorbs_";
$db_nopersist = 1;

Site identifictaion

As site identification, only the name of the administrator($mrbs_admin), his e-mail($mrbs_admin_email) and the name of the company/organization($mrbs_company) using Schoorbs could be set, this should be enough to let the user know on whoms page he is and he has to contact with problems.

Example configuration:

$mrbs_admin = "Mister Musterman";
$mrbs_admin_email = "mail@example.org";
$mrbs_company = "Example Company";

Calendar / Periods

Schoorbs offers two possibilities t adjust the bookable time units. On the one hand you could specify a fixed time span($resolution) in seconds apply for all units and crop the times when you can book a room by the start in hours($morningstarts) and minutes($morningstarts_minutes) and an end time in hours($eveningends) and minutes($eveningends_minutes). If you have choosen a day start of 7:30 and a resolution of 1800(-> 1/2h), so your clients are able too book units beginning at 7:30, 8:00, 8:30, ...
If your booking units do not have the same length, you should use named time units, called periods. These bookings are identified by their name, not by the time they start. The names of these units are stored in the array $periods. If you want to use this timing system instead of the first possiblity you have to set $enable_periods to true.
In general you could now addtionally choose, if a week stats on sunday($weekstarts = 0;) or on monday($weekstarts = 1;).

Example configuration with fixed time units:

$enable_periods = false;
$resolution = 2700;
$morningstarts = 8;
$eveningends   = 17;
$morningstarts_minutes = 0;
$eveningends_minutes = 0;
$periods[] = array();
$weekstarts = 1;

Example configuration with named time units(periods):

$enable_periods = true;
$resolution = 2700;
$morningstarts = 8;
$eveningends   = 17;
$morningstarts_minutes = 0;
$eveningends_minutes = 0;
$periods[] = "08:00-08:45";
$periods[] = "08:45-09:30";
$periods[] = "09:30-09:45";
$periods[] = "09:45-10:30";
$periods[] = "10:30-11:15";
$periods[] = "11:15-11:30";
$periods[] = "11:30-12:15";
$periods[] = "12:15-13:00";
$periods[] = "13:00-13:15";
$periods[] = "13:15-14:00";
$periods[] = "14:00-14:45";
$periods[] = "14:45-15:30";
$periods[] = "15:30-16:15";
$weekstarts = 1;

Authentication

The authentication is divided into two modular sections: 'authentication' (variable: $auth["type"]) and 'session' (variable: $auth["session"]).

The section 'session' provides the interface, which require the username and password from the client und saves it alongs several HTTP-requests. Availa are the moudles 'cookie' (Request of the password via HTML-GUI, saving username and password in a cookie), 'host' (the username is the hostname of the connected user, empty password), 'http' (username and password are requested via HTTP-authentication), 'ip' (the username is the ip of the connected user, empty password), 'php' (request of password/username via HTML-GUI, saves it with php's session_*-functions) and 'remote_user' (like 'http', but the authentication is done via the webserver, only the username will be submitted to Schoorbs).
Addition to 'http': The title of the HTTP-authentication could be set via the variable $auth['realm'].
Addition to 'remote_user': You could specify a link where the users could log themselves out: $auth['remote_user']['logout_link']

The validation of the combination of username and password is done by the module used in the section 'authentictation'. There are 4 modules available: 'config' (The username/password combination is stored in config.inc.php), 'db' (the combination will be stored in a database), 'ext' (a program will be executed to check the combination).
Addition to 'config': The username/password combination will be stored in the array $auth["user"], e.g.: $auth["user"]["nutzername1"] = "password1";
Addtition to 'ext': The executed programm is defined in the varibale $auth["prog"], the parameters are specified in $auth["params"], '#PASSWORD#' and '#USERNAME#' are placeholders.

The both sections control who could login, but they do not define who has adminstration privilegs and who not. People who should have those rights are listed in the array $auth["admin"], e.g. $auth["admin"][] = "nutzername1";.
Administrators are able to create new areas and rooms and could modify entries by other users.

Example configuartion ('session'='php' and 'type'='config'):

$auth["session"] = "php"; 
$auth["type"] = "config"; 
# The list of administrators (can modify other peoples settings)
$auth["admin"][] = "nutzername1"; 
# 'auth_config' user database
$auth["user"]["nutzername1"] = "password1";
$auth["user"]["nutzername2"] = "password2";

Language

In Schoorbs there not many language specific settings. In the common case documents will be delivered in UTF-8, at some place there is the possiblity to retract this via $unicode_encoding = 1;. Schoorbs tries to automatecally detect the language of the users, if this may fail, the language specified in $default_language_tokens which contains a two character language code(e.g. 'en'). By default the frequently asked questions will be displayed in English, but there are versions in Spain('_es'), German('_de') and French('_fr'), if you prefer one of these languages you should fill $faqfilelang with the fitting string.

Categories

Schoorbs gives you the choice to categorize your bookings. Herefor you have to the fill the array $typel with the description as the values and a uppercase letter between 'A' - 'J' as the index. Each letter colors the entry in a different style which defined via CSS(schoorbs-misc/style/style.css).

Example categories (with german scholar usage):

$typel["A"] = "Referat";
$typel["B"] = "normaler Unterricht";
$typel["C"] = "Kursarbeit";
# $typel["D"] = "D";
$typel["E"] = get_vocab("external");
# $typel["F"] = "F";
# $typel["G"] = "G";
# $typel["H"] = "H";
$typel["I"] = get_vocab("internal");
# $typel["J"] = "J";

Miscellaneous settings

Other configurations are e.g. the maximum number of repetetions is specified in ($max_rep_entrys). Additionally you could turn on the display of the times on the right side of the timetable with $times_right_side = true. With $javascript_cursor you could activate the highlighting of the current cell where the mouse is pointing at. When the user is accessing the index.php of Schoorbs he will see the timetable view defined in $default_view, either 'day', 'week' or 'month'.

Creative Commons License