index 3ad4fd81cd4c2a6244f15a105a2b1b3e50e4af16..07877ebad888efbd06fa916b142cc1b018edd5be 100644 (file)
/* Check for connection */
if (is_null($this->ldap) || (is_int($this->ldap) && $this->ldap == 0)){
$smarty= get_smarty();
- print_red (_("Can't bind to LDAP. Please contact the system administrator."));
+ msg_dialog::display(_("LDAP error"), _("Can't bind to LDAP. Please contact the system administrator."), ERROR_DIALOG);
display_error_page();
}
- if (!isset($_SESSION['size_limit'])){
- $_SESSION['size_limit']= $this->current['SIZELIMIT'];
- $_SESSION['size_ignore']= $this->current['SIZEIGNORE'];
+ if (!session::is_set('size_limit')){
+ session::set('size_limit',$this->current['SIZELIMIT']);
+ session::set('size_ignore',$this->current['SIZEIGNORE']);
}
if ($sizelimit){
- $this->ldap->set_size_limit($_SESSION['size_limit']);
+ $this->ldap->set_size_limit(session::get('size_limit'));
} else {
$this->ldap->set_size_limit(0);
}
}
if (isset($this->current['INITIAL_BASE'])){
- $_SESSION['CurrentMainBase']= $this->current['INITIAL_BASE'];
+ session::set('CurrentMainBase',$this->current['INITIAL_BASE']);
}
/* Remove possibly added ',' from end of group and people ou */
/* If no samba servers are found, look for configured sid/ridbase */
if (count($this->data['SERVERS']['SAMBA']) == 0){
if (!isset($this->current["SID"]) || !isset($this->current["RIDBASE"])){
- print_red(_("SID and/or RIDBASE missing in your configuration!"));
+ msg_dialog::display(_("Configuration error"), _("SID and/or RIDBASE missing in the configuration!"), ERROR_DIALOG);
display_error_page();
} else {
$this->data['SERVERS']['SAMBA']['DEFAULT']= array(