Today, XML is most definitely in the mainstream, and proving its mettle by making all kinds of new and unique applications possible (witness the success of Amazon.com's AWS service, or the Google APIs, both based on XML technology). This article provides an introduction to XForms, a recent W3C Recommendation that suggests using XML to manage the display, input and processing of form data on the Web.
Before getting into the details of how XForms works, it's important to understand the context in which it was developed and the need and rationale behind it.
You know that HTML already allows user interaction with a Web application, through the use of forms and associated form controls like text entry fields, checkboxes and radio buttons. However, although HTML forms are simple to understand and easy to use, they do have a couple of drawbacks:
HTML forms can usually be viewed (and used) only in a Web browser; they don't render too well on handhelds, cell phones or other devices.
Processing form input in the Web world usually requires the services of a programmer, who must code the business logic need for form data validation, input parsing and further data manipulation and processing.
Unless you put in a great deal of thought at the design stage (and sometimes not even then), HTML forms cannot be easily reused across different applications, or even within an application.
These drawbacks might seem trivial in the context of today's Internet. “It ain't broke,” you're probably thinking, “so why fix it?” But they assume serious proportions in the context of an XML world, which is built around data and the relationships inherent in it.