Re: PEAR_Info, " remote server error " ?
| From: | Davey | Date: | Tue, 13 May 2003 15:27:17 +0000 |
| Subject: | Re: PEAR_Info, " remote server error " ? | ||
| References: | 1 2 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-5352@lists.php.net to get a copy of this message | ||
This error occurs when a PEAR::isError call on the result of the remote package list call returns TRUE.
Also, the sample was a bit wrong, the PEAR_Info::setProxy line was *above* the require_once 'PEAR/Info.php'; line, however, I assume you didn't use that as it would have resulted in an error (the sample is fixed in CVS but doesn't warrant *another* release of PEAR_Info)
Try uncommenting the ini_set() lines, or setting them higher, also, check that you can run 'pear list-all' from the command line.
If you can do that, check that the proxy in use there (pear config-get http_proxy) is in use within the class by call this after $info->show();
echo $info->config->get('http_proxy');
if those do not match, uncomment the PEAR_Info::setProxy() and give the result from command line as the argument. Don't forget to move it below the require_once 'PEAR/Info.php'; either :)
Finally, make sure you don't need to pass your php_dir is correct.
(this is the configuration option name, although I feel its a bad name, should be pear_dir and as such I have called it that in my package)
You can check this by doing: pear config-get php_dir and passing the value given into the constructor of PEAR_Info:
$info = mew PEAR_Info('/path/returned/by/command/above');
Hope this helps.
- Davey
The Php_kid wrote:
Hi, I'm trying test file from PEAR_Info package, called "pear_info.php" on "test" folder. When I run it, I get a first box caller "Pear Config", but after this, an error appears: An Error occured fetching the package list from the remote server. Please try again. Have you an idea ? Thanks in advance -- ...ThE PhP_KiD.