Re: getting to grips with pear

From: Date: Sat, 25 Sep 2004 13:45:43 +0000
Subject: Re: getting to grips with pear
References: 1 2 3  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-14643@lists.php.net to get a copy of this message
Hi, Antoine, I know that George Pitcher wrote this, but I must respond:
On Sat, 25 Sep 2004 12:59:37 +0100, George Pitcher <george.pitcher@ingenta.com> wrote:
Antoine, I use PEAR:DB to handle my php-MySQL sites, but no other PEAR modules. I've found it really easy once I got to grips with the differences. I set up a confip.php file that gets loaded into every php script that needs db access. That contains the db connection stuff and creates the $db instance. I've changed my db structure so that I only use the following datatypes: varchar int tinyint text I store dates as 8-digit ints in the yyyymmdd format and use functions to encode/decode them from/to euro format dates.
This sounds almost exactly like PEAR::DB_Table in that it "forces" the database engine to store things in a compatible way instead of the database-native way. The date format is stored as a string in yyyy-mm-dd and time is a string hh:ii:ss, but other than that it sounds identical. DB_Table supports multiple databases (including Oracle) and has automatic table creation with automated form creation as well.
I am not stuck on pear, and if there are other things out there then am more than happy to go investigating. I will have a look at smarty also.
Be sure to take a look at Savant <http://phpsavant.com>; it is PEAR-compliant but not PEAR-accepted, and is a reasonable alternative to Smarty in that is is very powerful but also very easy to use. Hope this helps. -- pmj

« previous php.pear.general (#14643) next »