Home » Programming » PHP Tutorial

Writing Scripts with PHP\'s PEAR DB Module Topic:  PHP Tutorial
Download (280) times
Last Download at Friday 13th of January 2012 05:18:31 AM

Writing Scripts with PHP's PEAR DB Module

As a web programming language, one of PHP s strengths traditionally has been to make it easy to write scripts that access databases so that you can create dynamic web pages that incorporate database content. This is important when you want to provide visitors with information that is always up-to-date ...

This architectural approach has been used successfully with other languagesâ for example, to develop the DBI (Perl, Ruby), DB-API (Python), and JDBC (Java) database access interfaces. Itâ s also been used with PHP before; PHPLIB and MetaBase are two packages that provide an abstract database interface. How- ev er, PEAR is included with PHP distributions and installed by default, so if you have a recent version of PHP, you already have PEAR and can begin using it.

PEAR DB uses classes and objects to present an object-oriented interface, and this article assumes that you are familiar with PHPâ s approach to object-oriented programming. If you are not, you may wish to review the â â Classes and Objectsâ â chapter of the PHP Manual.

PEAR offers script writers control over the handling of PEAR errors. By default, PEAR calls return error objects. This enables you to do whatever you want with the error information (such as printing an error message), but on the other hand puts the burden on you to check the result of each call. Other approaches are possible. For example, if you donâ t want to test the result of every call, you can set the error handling mode to PEAR_ERROR_DIE to cause PEAR to print an error message and terminate the script automati- cally if an error occurs.
...
Source: www.kitebird.com

Download File Read PDF Online

Comments for Writing Scripts with PHP's PEAR DB Module


Related PDF Files

PHP Programming - Server Side Scripting Language

PHP stands for PHP Hypertext Processor. PHP is a server-side scripting language that is

Foresee PHP User Manual

Foresee PHP is a non-invasive, visual field analyzer, used as an aid to monitor Age-Rela

PHP Tutorial - Learn PHP

This tutorial is aimed at the PHP novice and will teach you PHP from the ground up. If you

PHP - Advanced Tutorial

PHP - Advanced Tutorial. Connecting MySQL with PHP, easy step for cookie handling, setup g

Using Ajax with PHP and Sajax

This tutorial is for those interested in developing rich Web applications that dynamicall

Incoming Search: