PEAR Articles
  Home arrow PEAR Articles arrow Page 2 - My PEAR: The Beginning
Codewalker Forums 
  Tutorials  
Database Articles  
Miscellaneous  
Navigation Usability  
PEAR Articles  
Programming Basics  
Server Administration  
XML Tutorials  
  Reviews  
Database Book Reviews  
Linux Book Reviews  
Miscellaneous Reviews  
PHP Book Reviews  
PHP Software Reviews  
Server Admin Reviews  
SQL Tool Reviews  
  Code Gallery  
Content Management Code  
Contest Code  
Counters Code  
Database Code  
Date Time Code  
Discussion Board Code  
Email Code  
File Manipulation Code  
GUI Code  
Link Farm Code  
Miscellaneous Code  
Search Code  
Site Navigation Code  
User Management Code  
Mobile Linux 
App Generation ROI 
IBM® developerWorks 
Download TestComplete 
Forums Sitemap 
Weekly Newsletter 
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
PEAR ARTICLES

My PEAR: The Beginning
By: David Web
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 5 stars5 stars5 stars5 stars5 stars / 1
    2008-09-17

    Table of Contents:
  • My PEAR: The Beginning
  • Installing PEAR
  • PEAR Coding Standards
  • Functions

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    My PEAR: The Beginning - Installing PEAR


    (Page 2 of 4 )

    Installing PEAR is very easy. I find that it is a bit more complicated to find a particular package for a project than to actually install PEAR. The first place to look when searching for a package is the PEAR home page at  http://pear.php.net/

    The PEAR package manager is bundled with all modern versions of PHP. Linux and Unix users do not explicitly have to install Package Manager as it is automatically installed. Windows users, however, have to go through the following steps (this guide assumes that you have installed php in c:php):

    • At the command prompt run the following:

      C:cd phppear

    • Once you are into the above directory, type:

      C:phppear>..php go-pear.php

    the following welcome message should then appear on the screen:

    Welcome to go-pear

    After the welcome screen, simply follow the instructions and all the currently available packages will be downloaded and installed.

    Now you are ready to use the Package Manager. The Package Manager is usually run from the command prompt or command shell. Provided you are the administrator or root, you should not have any problems operating the Package Manager. It has a lot of commands:

    • Install
    • Uninstall
    • Channel-add
    • Channel-alias
    • Channel-info
    • Channel-delete
    • Channel-update
    • List
    • List-all
    • Login
    • Logout
    • Makerpm
    • Package
    • Package-dependencies

    and so forth. 

    There are many more commands that you can use with Package Manager. The ones that we are interested in at this stage are install, uninstall and upgrade. Here's the syntax:

    pear install component_name


    pear uninstall component_name


    pear upgrade component_name


    Ensure that you enter the component name as it is; in other words, make sure to keep any capitalization, spacing and underscores intact. If everything went okay, you should get an "install ok" response. This means that the package has been installed successfully.

    A common error message that you will often encounter when installing packages will say something about a package having been deprecated. Don't worry about it. Some packages were written for PHP 4 and sometimes these packages contain syntax that PHP 5 just does not understand, so just ignore them.

    Later on we will install and test packages.

    More PEAR Articles Articles
    More By David Web


     

    PEAR ARTICLES ARTICLES

    - Deleting Authors from a PEAR Content Managem...
    - PEAR CMS: Index and Delete Scripts
    - Listing Articles for a PEAR Content Manageme...
    - Building an Authors Page for a PEAR CMS
    - Building the View Details Page in a PEAR CMS
    - Creating the Main Pages of a PEAR CMS
    - Completing the Login Script for a PEAR CMS
    - User Authentication for a PEAR CMS
    - A PEAR CMS: Examining the Code
    - Building a Content Management System with PE...
    - Installing a PEAR Package
    - My PEAR: The Beginning
    - Using XML_RPC2 with PEAR
    - Using Web Service APIs (Amazon and Yahoo!) w...
    - Database Abstraction with MDB2 from PEAR





    © 2003-2009 by Developer Shed. All rights reserved. DS Cluster 1 Hosted by Hostway
    Stay green...Green IT