Advertisement
Promo

Application development Toolkit

Speed PHP development with PEAR

Shelley Doll Builder.com

Published: 22 Oct 2002 09:57 BST

  • Email
  • Trackback
  • Clip Link
  • Print friendly
  • Post Comment

Time-to-delivery is an important factor when determining which technology to apply toward a solution, and PHP has taken on the challenge with PHP Extension and Application Repository (PEAR). PEAR is a code library that can reduce development time by supplying prewritten classes for standard functionality.

Similar in concept to Perl's CPAN, PEAR contains functionality for a number of features, including database, mail, and error handling. By using PEAR, developers can deploy and enhance basic functions that are already written and focus on writing new functionality.

PEAR basics
PEAR was created to provide a standardised means for developers to share PHP code and to promote use of reusable code. This project is an ongoing development effort, and users may submit code for acceptance into the PEAR library, which is bundled with PHP. All PEAR packages adhere to strict coding guidelines regarding syntax and readability conventions and consist of PHP or PHP extensions written in C.

Stig Bakken founded PEAR in late 1999. His goal was to create an organised code library that would serve as a community resource for PHP developers. The project has grown over the last two years and now contains a plethora of useful, reusable code. While there are other PHP repositories, such as Zend's Code Gallery and PHP Builder's Source Code Snippet Library, PEAR provides a level of standardisation that facilitates interoperability of functions. Additionally, submissions to PEAR are scrutinised by a panel, which provides quality assurance and reliability in the code.

Useful Web sites

Available functionality
PEAR is broken into three classes: PEAR Core Components, PEAR Packages, and PECL Packages. The Core Components include the base classes of PEAR and PEAR_Error, along with database, HTTP, logging, and e-mailing functions. The PEAR Packages include functionality providing for authentication, networking, and file system features, as well as tools for working with XML and HTML templates. PECL Packages are extensions to PHP, written in C, that do not comply with the coding guidelines. Currently, all code in this class is experimental. For more information on PEAR functionality, refer to the PEAR online manual.

If you're interested in submitting code for inclusion in PEAR, you can do so by joining the PEAR developer's mailing list and requesting that your code be reviewed. To be considered, be sure to pay attention to functionality that's already included and adhere to the PEAR coding guidelines.

Next

Previous

1 2


  • Email
  • Trackback
  • Clip Link
  • Print friendlyPrint with EPSON

Did you find this article useful?
73 out of 177 people found this useful


Full Talkback thread

0 comments

Company/Topic Alerts

Create a new alert from the list below:








Video icon

Video

Discussions

Tezzer Tezzer

Nice to see but...

Saturday 26 December 2009, 10:28 AM

5 comments
NoThomas NoThomas

Sure I can

Saturday 26 December 2009, 2:01 AM

11 comments

Win a Creative Zen X-Fi2 player and accessories

Win a Creative Zen X-Fi2 player and accessories

What is ZDNet UK's usual tagline?

Competition closes - 14 Jan 2010


Skip Sub Navigation Links to CNET Brand Links

Help

Become part of the ZDNet community.

Newsletters