Re: Configuration probleme
| From: | Davey | Date: | Mon, 08 Mar 2004 14:54:15 +0000 |
| Subject: | Re: Configuration probleme | ||
| References: | 1 2 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-11153@lists.php.net to get a copy of this message | ||
JaBro, Firman,
Since PEAR_Info 1.5 a new argument is available to the constructor
to supply a filename of a custom PEAR Config file - try using this :)
I'll try to make up some nice API Doc for PEAR_Info with examples on all these things soon - will be in FLA for a month starting wednesday but I do hope to have some time to code :)
- Davey
Firman Wandayandi wrote:
Hi JaBro, I think I know what's your problem. Yes you right, pear packages will not shown because the configuration is not correct. Pear_Info actually using PEAR_Config to grab configuration values, PEAR_Config actually will looking for pear configuration file. I found many vary directories where configuration file located, as below: 1. PHP_PEAR_SYSCONF_DIR (Environment Variables), filename = pear.ini, layer = user. 2. SystemRoot (Enviroment Variables), e.g C:\Windows, filename = pear.ini, layer = user. 3. PHP_SYSCONFDIR = Where php.ini located, filename = pear.ini, layer = user. 4. bin_dir = PEAR installed directory, filename = pear.conf, layer = system. 5. bin_dir/pear, filename = pear.conf, layer = system. If you set your configuration using via PEAR Web, you should be see at the top corner where the file "pear.conf" saved. After that try to run PEAR_Info(), this should be run properly, that's all. Note: There's some configuration may false again, to resolve it, just copy pear.conf and renamewith pear.ini and save in the same directory where php.inilocated. I hope I didn't forget something, someone please correct me if I'm wrong. Good Luck,Firman----- Original Message ----- From: "JaBro" <jabro@web.de> To: <fwd@vfemail.net> Sent: Monday, March 08, 2004 1:05 AM Subject: AW: [PEAR] Configuration problemeHi Firman, thx for helping me out here, I try to explain every step I've taken: I've created the little go-pear.php script and ran it. The configuration form asked me for my settings, this is what I've typedin:PEAR Executable directory c:\internet\pearablePEAR documentation directory: c:\internet\webpages\pear\docs PHP extension directory: c:\apache\php4\extensions PEAR directory: c:\internet\PEAR PEAR Installer cache directory: c:\internet\pear\cache PEAR data directory: c:\internet\PEAR\data PHP CLI/CGI binary: c:\apache\php4 PEAR test directory: c:\internet\webpages\pear\docs Cache TimeToLive: 3600 Preferred Package State: stable Unix file mask: 0 Debug Log Level: 1HTTP Proxy Server Address:PEAR server: pear.php.netPEAR password (for maintainers):Signature Handling Program: c:\internet\programme\gnupg\gpg.exe Signature Key Directory: c:\windows\pearkeysSignature Key Id:Package Signature Type: gpgPEAR username (for maintainers): My Document Root under Apache is c:\internet\webpages. I didn't think it's a good idea to have pear under document root so I've put it in c:\internet\pear and included it under php.ini after this i've run http://localhost/pear/index.php to start the webinstaller and configuration mask. There I downloaded the pear_info? package to beto work with Pear. Next Step I created the little Script below to start pearinfo <?php require_once 'PEAR\Info.php'; /* If you need to set a http_proxy value at run-time you can use the following, this must be called BEFORE instantiating the PEAR_Infoobject*/ PEAR_Info::setProxy('your.proxy.here'); /* Optional pear_dir variable, allows you to choose where your PEAR install is, in case its not found */ $pear_dir = ""; /* Instantiate PEAR_Info object */ $info = new PEAR_Info($pear_dir); /* Show PEAR_Info output */ $info->show(); ?> the output I get there is: all directories there are false for the PEAR config table, but the pear packages are not shown probably because all directories are false. I hope I've explained every step and hope I didn't forget anything. Thanks for helping. JaBro P.s. I'm not familiar with the command prompt with php. If I need that please tell me exactly what I need to get started there. PHP starts after cd\apache\php4\php.exe Hi, JaBro I'm really sorry, I litte confussion with your message. I want to help you, because I run PEAR on Windows XP too and no problems. Can you explain it more detail, or maybe someone understand about your problem?. Regards, Firman ----- Original Message ----- From: "JaBro" <jabro@web.de> To: <pear-general@lists.php.net> Sent: Sunday, March 07, 2004 3:23 PM Subject: [PEAR] Configuration problemealmostHi list, I hope this isn't a big thing. Whenever I start a Pear_Info() I getc:\internet\pearthe expected result back. But: 1. in the PEAR Config block: None of the directories seem to be right e.g. bin_dir isc:\internet\pear\PEAR\Info.php(which is included in php.ini) but listed is c:\php4 which is nonsense php should be in c:\apache\php4 2. in the PEAR Packages Block: It doesn't show any of the installed packages instead I receive the following warning: Invalid argument supplied for foreach() inon line 238 which is probably a result of the above I've been trying to locate something like a configuration file, butcouldn'tfind anything. What do I have to do to get my System to run with pear? Here some additional information: I've got Apache 1.3.20 and PHP 4.3.1 on winXP. The PEAR Frontend is in c:\internet\webpages\pear where (c:\internet\webpages\ is root) pear itself is in c:\internet\pear thx Jabro -- PEAR General Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php