diff options
| author | Chuck Hagenbuch <chagenbu@php.net> | 2001-01-04 15:56:05 +0000 |
|---|---|---|
| committer | Chuck Hagenbuch <chagenbu@php.net> | 2001-01-04 15:56:05 +0000 |
| commit | 542fa4eacee3b546c9e7699e82e154272224ad3f (patch) | |
| tree | 1382adf18e1e10c0e86520b66604d15b8d5fabc3 | |
| parent | db0be122d2e95e739c2018f93856a005a8cdaed6 (diff) | |
| download | php-git-542fa4eacee3b546c9e7699e82e154272224ad3f.tar.gz | |
fix the Log::factory() method to assume that the Log stuff is in the
include_path (like all of PEAR does).
| -rw-r--r-- | pear/Log.php | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/pear/Log.php b/pear/Log.php index ac10b226b2..f4c029c002 100644 --- a/pear/Log.php +++ b/pear/Log.php @@ -1,4 +1,5 @@ <?php +// $Id$ // $Horde: horde/lib/Log.php,v 1.15 2000/06/29 23:39:45 jon Exp $ /** @@ -52,9 +53,8 @@ class Log { */ function factory ($log_type, $log_name = '', $ident = '', $conf = array()) { $log_type = strtolower($log_type); - $classfile = dirname(__FILE__) . '/Log/' . $log_type . '.php'; - if (@is_readable($classfile)) { - include_once $classfile; + $classfile = 'Log/' . $log_type . '.php'; + if (@include_once $classfile) { $class = 'Log_' . $log_type; return new $class($log_name, $ident, $conf); } else { |
