Using HTML_QuickForm To Manage Web Forms, Part 1
(Page 1 of 13 )
Tired of authoring dull and dreary Web forms everyday? Fed up of programming JavaScript validations day-in and day-out? Then, the HTML_QuickForm package is just the solution for which you are looking. In the first part of this two-part tutorial, I'll get you started with the basics of building Web forms using this resourceful PEAR package.
SOS - Search fOr a Solution
Recently, I took on a project for the development of a community portal to be deployed on the LAMP platform - my platform of choice. My first responsibility was to build a prototype that allowed users to sign-up using a simple Web form. In such a scenario, the usual reaction of a programmer is to slap together a page using the WYSIWYG features of his (or her) favorite HTML editor, pull out JavaScript libraries from archived projects and pilfer PHP code snippets to manage the database interaction. And voila - the prototype is ready to roll!
Since I was very keen to break out of this cut-copy-paste routine, I decided to search for a solution that would streamline the process of building such Web forms. One of my goals during this research was to look for a mechanism that would allow me to focus on implementing the business logic associated with the application rather than worry about mundane things like writing the HTML code or scripting validations using JavaScript.
I began with a quick review of some popular "templating" engines. While most allowed me to abstract programming logic from the user-interface, the responsibility of authoring a template - in other words, writing the HTML code - rests with the programmer. This was a definite no-no!
Then, I came across the HTML_QuickForm package on the PEAR Web site. The official summary for the package stated that the package "provides methods for creating, validating, processing HTML forms. I knew that I'd finally struck gold!
Want to know more? Read on!
Next: Installing The HTML_QuickForm Package >>
More Design Usability Articles
More By Harish Kamath