RE: [xml] Relative path to DTD: should it work?

Daniel, thanks for the reply. I was just about to post that the problem
appears to be one of my own making. Instead of:

xmlTextReader *reader = xmlReaderForMemory(pStart, len, NULL, NULL,

I needed to be doing:

xmlTextReader *reader = xmlReaderForMemory(pStart, len, fn, NULL,

so that the entity loader would have some base URI to use as a reference
point. Sorry!

-----Original Message-----
From: Daniel Veillard [mailto:veillard redhat com] 
Sent: Thursday, November 04, 2004 6:58 PM
To: Parag Chandra
Cc: xml gnome org
Subject: Re: [xml] Relative path to DTD: should it work?

On Thu, Nov 04, 2004 at 01:19:05PM -0500, Parag Chandra wrote:
<!DOCTYPE qa SYSTEM "qa.dtd">

When I try to validate this document against the DTD, libxml2
with 'failed to load external entity "qa.dtd"'. If I modify the entity
path to be absolute, as in

  strange, that shoudl work.

<!DOCTYPE qa SYSTEM "c:/development/qa.dtd">

  Warning, a system identifier is an URI-Reference, not a file path !
What you pasted is likely to not work.

it works. I've tried searching in the mailing archive, and it seems

  strange again, there is some specific Windows code trying to deal
with that filepath/URI-Reference conflict ...


Daniel Veillard      | Red Hat Desktop team
veillard redhat com  | libxml GNOME XML XSLT toolkit | Rpmfind RPM search engine

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]