Home > Ask the SOA Experts > Questions & Answers > Using XML DOM object to make a database call
Ask The SOA Expert: Questions & Answers
EMAIL THIS

Using XML DOM object to make a database call

Sean McGrath EXPERT RESPONSE FROM: Sean McGrath

Pose a Question
Other SOA Categories
Meet all SOA Experts
Become an Expert for this site
>
QUESTION POSED ON: 28 February 2002
On my Web page (IE5.0), I am using XML DOM object to make a database call. The result set is received in XML format by the client function (javascript) which parses it. If my XML text content contains the character '(r)' then on some user machine the parser errors with a message 'invalid character in the text content'. On most other systems, it handles it just fine. What is the problem and how can I fix it? Here is a sample of XML text:

<ResultSet>
         <Record>
                 <Name>
                         <![CDATA[Intel(r)
PRO-10-100-1000-Wireless]]>
                 <Name>
        </Record>
</ResultSet>

>

The problem here is not to do with the "(r)". There are two problems with your sample XML:

1. The CDATA section markup has been rendered incorrect by the replacement of "[" and "]" characters with references to characters 91 and 93. Using character references rather than characters themselves hides the CDATA section from the parser. I doubt that this is what you want to do.

2. There is a <Name> start-tag where the end-tag should be (before the Record end-tag.


Digg This!    StumbleUpon Toolbar StumbleUpon    Bookmark with Delicious Del.icio.us   



RELATED RESOURCES
2020software.com, trial software downloads for accounting software, ERP software, CRM software and business software systems
Search Bitpipe.com for the latest white papers and business webcasts
Whatis.com, the online computer dictionary



Search and Browse the Expert Answer Center
Search and browse more than 25,000 question and answer pairs from more than 250 TechTarget industry experts.
Browse our Expert Advice



SOA Governance White Papers - BPM, EDA, IT Governance
About Us  |  Contact Us  |  For Advertisers  |  For Business Partners  |  Site Index  |  RSS
SEARCH 
TechTarget provides technology professionals with the information they need to perform their jobs - from developing strategy, to making cost-effective purchase decisions and managing their organizations' technology projects - with its network of technology-specific websites, events and online magazines.

TechTarget Corporate Web Site  |  Media Kits  |  Site Map




All Rights Reserved, Copyright 2001 - 2009, TechTarget | Read our Privacy Policy
  TechTarget - The IT Media ROI Experts