Hm, it looks like the package was originally written for PHP 4 and not fully compatible with PHP 5.3.
The 'deprecated'-error means a language construct is used which is deprecated in PHP 5.3 (but it was probably needed for PHP 4).
- Code: Select all
&new PEAR_Registry
The 'deprecated'-error is not a fatal error, but a sort of warning that the used language construct will be removed in the next major PHP version (probably PHP 6). You can hide these messages by setting the error reporting.
To turn off deprecated warnings at PHP script level, type for example
- Code: Select all
error_reporting(E_ALL ^ E_DEPRECATED);
to hide deprecated errors, but show most others. Type those lines before including PEAR code, if possible. If it is not possible, you can also choose to set the error reporting in the php.ini:
- Code: Select all
error_reporting = E_ALL & ~E_DEPRECATED
http://php.net/manual/en/function.error-reporting.php (function)
http://php.net/error_reporting (php.ini)
The second error can mean two things:
- A file (which contains the PEAR_Config class) got included twice.
- There are two files included which both got a PEAR_Config class.
I'm not sure what's the best way to fix this.
If it's the case that there are two PEAR_Config classes, you could try to comment out one of them, but it's possible that this will lead to unexpected results. If it's the case that the config-file got included twice, you should look up the places where the config-file got included and change the code from 'include' to 'include_once' or from 'require' to 'require_once'.
http://php.net/include_oncehttp://php.net/require_onceI'm not sure if you can fix it the way I described above. I thought it was the case that PEAR would be dynamically loaded before your own PHP-scripts gets loaded, but since I never have done anything with PEAR yet, I don't know if that is the case.
If you can't get the errors fixed, I think you should ask the PEAR-community for help.