What's new with MSXML 4.0?
By Ed Tittel
If you're interested in looking at XML markup from inside the confines of a Web browser, you can't always rely on that browser to know what to do with XML unaided. For Microsoft Internet Explorer users, the answer to this problem was a utility named MSXML 3.0--that is, until Microsoft announced its Microsoft XML Parser 4.0 Technology Preview in mid-April. Because this new release portends some powerful extensions to the world's most popular Web browser's abilities to deal with XML documents, I present a brief overview and some commentary on its new capabilities here. For the full story on this fascinating topic, please visit http://msdn.microsoft.com/xml/general/newinaprilre.asp for the official story, and http://www.xml.com/pub/r/1071 for xml.com's equally interesting discussion of this tantalizing bit of pre-release software.
Here's a short, briefly annotated list of what's new with MSXML 4.0, which I hope you find as interesting as I do:
- Support for the latest version of XML Schemas (proposed recommendation dated 3/20/2001), including XML Schema Definition (XSD) validation in the document object model, or DOM, and XSD support in XPath and XSLT. In essence, this means that MSXML 4.0 will do as good a job of supporting XML Schemas as is currently possible, given that they're still in flux themselves. But given their increasing importance (and inclusion in other XML application definitions) support for XML Schemas is no longer a "nice-to-have" but rather a "must have" capability.
- MSXML 4.0 will be able to validate XML documents against XML Schemas (except for handling regular expressions, which is supposed to be added in a later release). Likewise, MSXML will continue to handle XML-Data Reduced (XDR) and document type definition based XML document validations. This means it can use all legal XML document definition mechanisms as the basis for mechanical validation.
- Integration between the two most widely used parsing models for processing XML documents, namely the document object model (DOM) and the simple API for XML (SAX). From here on out, MSXML will work equally well with both parsing models, and can even convert between the two, given the proper tools. Microsoft has even taken steps to support SAX methods for emitting HTML when parsing and processing XML documents, in much the same way that XSLT permits HTML to be emitted in a results tree from the same XML document. In a very tight nutshell, this makes it easier for content developers to use common, handy tools to process XML, rather than having to be extremely picky about which tools work with which browsers.
- MSXML 4.0 will be able to recognize, track, and resolve qualified XML element names within documents, when multiple namespaces are used, and where name prefixes become necessary to fully distinguish unique element names. Here, this means that MSXML 4.0 will be able to handle complex names correctly and properly.
All this said, given that MSXML 4.0 is a preview technology--that is, a hopefully helpful look at pre-release capabilities--I can't recommend that you start building production capabilities around this seemingly excellent tool. While it provides a great look at what's coming soon, it's not production code yet, so it shouldn't be used for production purposes. So download it, explore its capabilities, and use it to plan what the coming generation of XML-enabled Web browsers will be able to do with XML documents! You can grab MSMXL 4.0 from http://msdn.microsoft.com/downloads/default.asp?URL=/code/sample.asp?url=/msdn-files/027/001/594/msdncompositedoc.xml.
Ed Tittel is a principal at LANWrights, Inc., a wholly owned subsidiary of LeapIt.com. LANWrights offers training, writing, and consulting services on Internet, networking, and Web topics (including XML and XHTML), plus various IT certifications (Microsoft, Sun/Java, and Prosoft/CIW).
Did you like this tip? We'd like to know what you think, so if you email us we can find out.
XML™: Your visual blueprint for building expert Web pages
Author : Emily A. Vander Veer
Publisher : Hungry Minds
Published : Nov 2000
XML (Extensible Markup Language) allows Web developers to enhance database connectivity, enrich pages with specialized data elements, and otherwise move beyond the limitations of HTML. This highly visual tutorial demonstrates over 100 different XML operations, from formulating Document Type Definitions (DTDs) to setting up styles with Extensible Stylesheet Language (XSL). The CD-ROM contains code examples and an e-version of the book.