Manage Learn to apply best practices and optimize your operations.

The benefits of modularization

Why modules in XHTML are a good thing.

XML Developer Tip
(Receive this column in your inbox,
click Edit your Profile to subscribe.)

The benefits of modularization
Ed Tittel

Those who've been reading my XML tips for a while may recall some discussions of XHTML modularization I covered last year. In the process of building some XML applications recently, I was forcibly reminded of this technology as I sought to combine pre-existing standard XML components with some customized XML markup of my own.

For those who may not already know, XML (or XHTML) modularization is a technique whereby a document type definition (DTD), XML Schema, or some other kind of document description (Schematron, RELAX NG, and so forth) is actually composed of a collection of modules, each of which in turn has its own component DTD, XML Schema definition, or what have you. The basic idea is to compartmentalize discrete areas of functionality so that such areas can be mixed and matched (and even customized) as particular sets of documents might require.

Thus, the modules that make up XHTML include a collection of core modules that define basic HTML/XHTML markup, text extension modules, forms modules, table modules, image and image map modules, and more (for the complete details, please see "Modularization of XHTML"). By creating a DTD or Schema that invokes the right set of constituent modules, Web content developers can create special subsets of the entire XHTML module collection (as is common for those who develop for hand-held devices like PDAs or Web-enabled cellphones).

More to the point of this tip, I found myself wanting to use basic HTML text-handling capabilities, along with some special-purpose address book record-handling features. By creating a modular DTD for my custom markup and combining it with the Core XHTML modules, I was able to build a quick and complete application with very little additional effort above and beyond the component DTD for my address book records. This kind of approach works well for many kinds of applications and is highly recommended for developers who have needs to access custom datatypes, but who also wish to leverage existing XML-based functionality.

About the Author

Ed Tittel is a principal at LANWrights, Inc., a network-oriented writing, training, and consulting firm based in Austin, Texas. He is the creator of the Exam Cram series and has worked on over 30 certification-related books on Microsoft, Novell, and Sun related topics. Ed teaches in the Certified Webmaster Program at Austin Community College and consults. He a member of the NetWorld + Interop faculty, where he specializes in Windows 2000 related courses and presentations.

For More Information:

  • Looking for free research? Browse our comprehensive White Papers section by topic, author or keyword.
  • Are you tired of technospeak? The Web Services Advisor column uses plain talk without the hype.
  • For insightful opinion and commentary from today's industry leaders, read our Guest Commentary columns.
  • Hey Codeheads! Start benefiting from other time-saving XML Developer Tips and .NET Developer Tips.
  • Visit our huge Best Web Links for Web Services collection for the freshest editor-selected resources.
  • Choking on the alphabet soup of industry acronyms? Visit our helpful Glossary for the latest lingo.
  • Visit Ask the Experts for answers to your Web services, SOAP, WSDL, XML, .NET, Java and EAI questions.
  • Discuss this issue, voice your opinion or just talk with your peers in the SearchWebServices Discussion Forums.

Dig Deeper on Topics Archive

Start the conversation

Send me notifications when other members comment.

Please create a username to comment.