In this second part of a two-part article, you'll learn how to install a PEAR package, include a package within your scripts, and more. This article is excerpted from chapter 11 of the book Beginning PHP and Oracle: From Novice to Professional, written by W. Jason Gilmore and Bob Bryla (Apress; ISBN: 1590597702).
Learning More About an Installed PEAR Package
The output in the preceding section indicates that nine packages are installed on the server in question. However, this information is quite rudimentary and really doesn’t provide anything more than the package name and version. To learn more about a package, execute the info command, passing it the package name. For example, you would execute the following command to learn more about the Console_Getoptpackage:
%>pear info Console_Getopt
Here’s an example of output from this command:
ABOUT CONSOLE_GETOPT-1.2
========================
Provides
Classes: Console_Getopt
Package
Console_Getopt
Summary
Command-line option parser
Description
This is a PHP implementation of "getopt"supporting both short and long options.
Maintainers
Andrei Zmievski <andrei@php.net> (lead) Stig Bakken <stig@php.net> (developer)
Version
1.2
Release Date
2003-12-11
Release License
PHP License
Release State
stable
Release Notes
Fix to preserve BC with 1.0 and allow correct behaviour for new users
Last Installed Version
- None -
Last Modified
2005-01-23
As you can see, this output offers some very useful information about the package.