Search This Blog

Wednesday, August 29, 2007

Use PHP to Create XForms

This two-part article series is designed to get PHP developers up to
speed in leveraging Web 2.0 XForms forms for their PHP forms development
so that they can finally put their outdated Web 1.0 HTML forms away.
This will be accomplished by creating a library of functions that
generate XForms elements when called upon. In Part 1 of a two-part
series, developers will create the XForms library using PHP, allowing
each function to take in parameters and output XForm elements. XForms
is a great Web 2.0 language with exciting features that allow developers
to create cutting-edge forms. And why not use it with PHP? PHP
developers traditionally output HTML, which generally limits the
capabilities of their forms. The problem with XForms, however, is that
the file type is strictly XHTML, which is a more refined version of
HTML in that the XML format is strict, and doesn't allow mistakes,
mismatched tags being one of them. On top of that, there is regular
syntax for XForms, which can make the learning curve of XForms a bit
steep for some PHP developers who are possibly just learning the PHP
language itself. For this article you'll need PHP 5 and the Firefox
XForms plugin. This article series was tested using PHP5 on WAMP5
Server Version 1.7.1 running Apache 2. In Part 2 of this article we
will enhance the library just created with error checking and
convenience methods. We will also use the library in Part 2 to create
a proof of concept form. Check Here

No comments: