magazine resources subscribe about advertising

New Architect Daily
Commentary and updates on current events and technologies

CMP Media E-Book

Download your copy today.

Research
Search for reports and white papers from industry vendors and analysts.

This Week at NewArchitect.com Subscribe now to our free email newsletter and get notified when the site is updated with new articles







Day of Defeat Online Gaming

 New Architect > Archives > 2000 > 08 > XML@Large  

Debugging XML Applications

By Michael Floyd

When developing XML applications, it's often necessary to use several technologies to manage data. As a developer, you must first design schema to represent the data, use markup to describe it, DTDs to validate it, XSL to transform and present it, and the DOM to access and modify it programmatically. In a client-server arrangement, you also have to deal with the technologies of the existing infrastructure.

Because there are so many factors in a single XML application, it's not always easy to tell where things went wrong when a document doesn't display correctly. This is particularly true when generating XML dynamically from a server, because you never see the XML that's being generated. It's possible to spend hours debugging the program. So what can you do to locate the problem quickly and solve it?

Debugging Strategies

Debugging a static XML document is relatively straightforward. All you need do is run the document through a parser, which will show you where there are formatting errors. However, when debugging applications that generate XML on the fly, your chances of finding the errors in the document are slim. Because the document lives (and dies) in memory, you never actually get to see the XML that's being generated. There's no physical XML file to run through a parser.

In this case—actually, in any case—the first thing you want to do is ensure that your XML document is well formed. If the data being generated isn't well formed, the parser fails to generate any output, and if your application is supposed to produce a resulting HTML document you'll typically end up with a blank screen instead.




  Day of Defeat Online Gaming

home | daily | current issue | archives | features | critical decisions | case studies | expert opinion | reviews | access | industry events | newsletter | research | careers | info centers | advertising | subscribe | subscriber service | editorial calendar | press | contacts


Copyright © 2006 CMP Media, LLC Read our privacy policy, your California privacy rights, terms of service.
SDMG Web sites: BYTE.com, C/C++ Users Journal, Developer Pipeline, Dr. Dobb's Journal, DotNetJunkies, MSDN Magazine, Sys Admin,
SD Expo, SD Magazine, SqlJunkies, The Perl Journal, Unixreview, Windows Developer Network, New Architect

web2