If you program in PHP then you should know the power that the PEAR Library provides. If not make sure you look into it because it can save you hours of programming time. One of the overlooked functions in this library is the HTML_QuickForm function. This allows you to create forms in HTML and also add validating functionality to it. Good stuff.
I recently needed to develop an HTML form to input and edit contact details in a database with the usual name, address, telephone, and web page fields. This very common task is made more complex because of the need to validate the input data according to various rules and to notify the user if the validation process fails. I’m also always keen to separate the presentation logic (typically HTML) from the programming logic (PHP, in this case).








Paul, have you seen any good articles on what it takes to actually use PEAR? Like what I need to add to my server, etc? I’ve never worked with it, but it seems to be very useful… but last time I went to their site, their documentation was so far off the useless chart that I was convinced it’d been written by Condi Rice.
An Introduction to PEAR
A Detailed Look at PEAR
Those might be able to help you out.
It sounds nifty, but it doesn’t seem to lend itself (as the quote noted above) to separation of programming and presentation. Perhaps, I’m missing something?
Also, while PEAR is very handy and very functional, it’s getting a little bloated. And, correct me if I’m wrong, but I’m not yet confident in its compatibility with PHP5 (my main development language). This, of course, isn’t an issue for most.
I have yet to touch PHP5 in production type use so I can’t comment on the combatibility of it, but I don’t see why it would be an issue. However, I am sure it would look much better and be much less bloated if they re-engineered it with the OOP capabilities of PHP5.