When using PHP >= 4.3.0, the PEAR Package Manager is already
installed unless one has used the ./configure
option --without-pear.
If one uses a version of PHP that is supplied by Unix/Linux/BSD
distributors it may be necessary to manually install PEAR. Users
should consult the documentation for the respective distribution
in this case.
For all versions prior to 4.3.0 or if you want to re-install the
Package Manager, you can use the following provisional way:
$ lynx -source http://go-pear.org/ | php
|
Note:
Some Linux distributions (e.g. Redhat) seem to be using
links instead of lynx
as the name for their command line browser. If this is the case
for you, you need to change the above line correspondingly.
After you have downloaded and installed PHP, you have to manually
execute the batch file located in e.g.
c:\php\go-pear.bat. The setup will ask you
some questions and afterwards the PEAR Package Manager will be
installed in the path, which you have specific during installation.
Finally you have to add that installation path to your
PATH environment. Either do this manually (Start >
Control Panel > System > Environment) or run (double-click) the
newly generated PEAR_ENV.reg that's now found in the
PHP source directory. After that you can access the PEAR Package Manager
by running the command pear in a Windows Command
Prompt.
To update your PEAR installation from go-pear.org, request
http://go-pear.org/ in your browser and save the output to a local
file go-pear.php. You can then run
in a Windows Command Prompt to start the update process.
If you are running your site at a web hosting provider with no
direct access to the server (via local logins, Telnet or SSH), you
can't use the PEAR Installer unless you are using PEAR_RemoteInstaller and have
ftp access (sftp access is not yet supported).
Warning |
FTP as a protocol is inherently insecure, as passwords are sent unencrypted.
|
If you are customer of a
smart web hosting company, the chances are very well that the
most commonly used PEAR packages are already installed on the
machine that is hosting your site. If that is not the case or if
you need additional packages, you should contact your provider and
ask them nicely to install the package. If they refuse to do so,
you can either look for a new web hosting company or you can
install the package
manually.