root / class / utils.class.php @ cb527757
1 |
<?php
|
---|---|
2 |
|
3 |
abstract class utils { |
4 |
static public function init() { |
5 |
function __autoload($class) { |
6 |
$class_loc = 'class/'.$class.'.class.php'; |
7 |
if (is_readable($class_loc)) { |
8 |
require_once($class_loc); |
9 |
} |
10 |
} |
11 |
|
12 |
function errorToException($code, $msg, $file, $line) { |
13 |
throw new Exception($msg); |
14 |
} |
15 |
set_error_handler('errorToException'); |
16 |
} |
17 |
|
18 |
} |