| | |
| | | ini_set('error_log', $this->prop['log_dir'].'/errors'); |
| | | } |
| | | } |
| | | if ($this->prop['debug_level'] & 4) { |
| | | ini_set('display_errors', 1); |
| | | } |
| | | else { |
| | | ini_set('display_errors', 0); |
| | | } |
| | | |
| | | // enable display_errors in 'show' level, but not for ajax requests |
| | | ini_set('display_errors', intval(empty($_REQUEST['_remote']) && ($this->prop['debug_level'] & 4))); |
| | | |
| | | // export config data |
| | | $GLOBALS['CONFIG'] = &$this->prop; |
| | |
| | | */ |
| | | public function set_user_prefs($prefs) |
| | | { |
| | | // Honor the dont_override setting for any existing user preferences |
| | | $dont_override = $this->get('dont_override'); |
| | | if (is_array($dont_override) && !empty($dont_override)) { |
| | | foreach ($prefs as $key => $pref) { |
| | | if (in_array($key, $dont_override)) { |
| | | unset($prefs[$key]); |
| | | } |
| | | } |
| | | } |
| | | |
| | | $this->userprefs = $prefs; |
| | | $this->prop = array_merge($this->prop, $prefs); |
| | | $this->prop = array_merge($this->prop, $prefs); |
| | | } |
| | | |
| | | |