tags:

views:

42

answers:

1

Hi,

I am using MSXML3 and have loaded an xml document which is a HTML page. I found that if I do not set the resolveExternals property to false (and validateOnParse to false), I get the following error:

"The server did not understand the request, or the request was invalid.' 'Error processing resource 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'.'

Can anyone explain why I need resolveExternals set to false?

JD

+1  A: 

The parser is most likely trying to load that resource (the .dtd) from the remote site w3.org, and failing. Do you have a net connection from that process (perhaps with appropriate proxy configuration) ?

You should be able to specify a local copy of the .dtd to load instead if you don't want your process to load this remotely (usually a good idea).

Brian Agnew
Hi Brian, thanks for the reply. I have a net connection so that is not it. Doing some more research, if I try to validate the document with validateOnParse = true (resolveexternals=true), I get the error "Validate failed because the document does not contain exactly one root node". The document has the structure: '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">'<html xmlns="http://www.w3.org/1999/xhtml">'<head> etc....From what I understand, it should get the DTD and validate it.Any ideas?Thanks.JD.
JD
Just tested with AltovaXML 1.0 and validating the document seems to be fine without giving any sort of errors.
JD