OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

docbook-apps message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: xi:include makes XML doc invalid; xmllint says so; seems wrong


I am trying to use xi:include in a very simple document just to make 
sure I can get it to work before I use it in a real document. I am 
trying to repeat the technique used in the "Validating with XIncludes" 
section in Chapter 19. Modular DocBook Files of DocBook XSL: The 
Complete Guide.

Perhaps I have missed something obvious. Any suggestions?

I use the following command:

xmllint --noout --nonet --valid --xinclude --postvalid front.xml

I get the following errors messages:

***************************************
front.xml:8: element include: validity error : 
No declaration for attribute xmlns:xi of element include
<xi:include  href="legal.xml" xmlns:xi="http://www.w3.org/2003/
XInclude">
front.xml:8: element include: validity error : No declaration for 
attribute href of element include
<xi:include  href="legal.xml" xmlns:xi="http://www.w3.org/2003/
XInclude">
front.xml:11: element fallback: validity error : No declaration for 
element fallback 
</xi:fallback>
front.xml:12: element include: validity error : No declaration for 
element include
</xi:include>
front.xml:13: element bookinfo: validity error : Element bookinfo 
content does not follow the DTD, expecting (graphic | mediaobject | 
legalnotice | modespec | subjectset | keywordset | itermset | abbrev 
| abstract | address | artpagenums | author | authorgroup | 
authorinitials | bibliomisc | biblioset | collab | confgroup | 
contractnum | contractsponsor | copyright | corpauthor | corpname | 
date | edition | editor | invpartnumber | isbn | issn | issuenum | 
orgname | biblioid | citebiblioid | bibliosource | bibliorelation | 
bibliocoverage | othercredit | pagenums | printhistory | productname 
| productnumber | pubdate | publisher | publishername | pubsnumber | 
releaseinfo | revhistory | seriesvolnums | subtitle | title | 
titleabbrev | volumenum | citetitle | personname | honorific | 
firstname | surname | lineage | othername | affiliation | authorblurb 
| contrib | indexterm)+, got (title xi:include )
  </bookinfo>
***************************************

But the XML document front.xml is very simple and it seems to me that 
this is a valid document:
*******  front.xml    **********************
<?xml version="1.0" encoding="ISO-8859-1"?>
<!DOCTYPE bookinfo PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd";>
  <bookinfo>
    <title>Title</title>
    <xi:include  href="legal.xml" 
        xmlns:xi="http://www.w3.org/2003/XInclude";>
      <xi:fallback>
        <para><emphasis>FIXME:  MISSING XINCLUDE CONTENT
                    </emphasis></para>
      </xi:fallback>
    </xi:include>
  </bookinfo>
*****************************

And the document legal.xml is very simple:
********  legal.xml   *********************
<!DOCTYPE legalnotice PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd";>
    <legalnotice>
      <para>
      </para>
    </legalnotice>
*****************************

Here's the info on my xmllint version:
xmllint: using libxml version 20606
compiled with: DTDValid FTP HTTP HTML C14N Catalog XPath XPointer 
XInclude Iconv Unicode Regexps Automata Schemas

Thanks for any help you can offer. 

Steve Whitlatch



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]