Validation errors on xi:include
Having trouble installing Oxygen? Got a bug to report? Post it all here.
Validation errors on xi:include
Post by Guest »
When trying to validate the document, I get errors if the document contains xi:include.
For example:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE chapter PUBLIC "-//INVERA//DTD DocBook XML V4.2-Extension//EN"
"http://ourDocBook.dtd">
<chapter id="ch-xml-dtd" xmlns:xi="http://www.w3.org/2003/XInclude">
<title>Documentation Type Definitions</title>
<para/>
<xi:include href="dtd.xml"/>
<xi:include href="xml-doc-validation.xml"/>
</chapter>
The errors:
Attribute "xmlns:xi" must be declared for element type "chapter".
Element type "xi:include" must be declared.
Unexpected element "xi:include". The content of the parent element type must match "(beginpage?,chapterinfo?, ...
For example:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE chapter PUBLIC "-//INVERA//DTD DocBook XML V4.2-Extension//EN"
"http://ourDocBook.dtd">
<chapter id="ch-xml-dtd" xmlns:xi="http://www.w3.org/2003/XInclude">
<title>Documentation Type Definitions</title>
<para/>
<xi:include href="dtd.xml"/>
<xi:include href="xml-doc-validation.xml"/>
</chapter>
The errors:
Attribute "xmlns:xi" must be declared for element type "chapter".
Element type "xi:include" must be declared.
Unexpected element "xi:include". The content of the parent element type must match "(beginpage?,chapterinfo?, ...
-
- Site Admin
- Posts: 2095
- Joined: Thu Jan 09, 2003 2:58 pm
Hi,
The xi:include element should be defined in your DTD. Please see the customization layer we added in the Docbook samples that came with the Oxygen 4 distribution.
samples/docbook/sampleXInclude.xml - the master file
samples/docbook/section1.xml - included file
samples/docbook/section2.xml - included file
samples/docbook/section3.xml - included file
docbook/dtd/xinclude.mod - the module with the XInclude customization
There are also some document templates that can give you a quick start about working with Docbook and XInclude, see the "Docbook 4.2 article with XInclude" that is available in the "New from templates" dialog.
Best Regards,
George
The xi:include element should be defined in your DTD. Please see the customization layer we added in the Docbook samples that came with the Oxygen 4 distribution.
samples/docbook/sampleXInclude.xml - the master file
samples/docbook/section1.xml - included file
samples/docbook/section2.xml - included file
samples/docbook/section3.xml - included file
docbook/dtd/xinclude.mod - the module with the XInclude customization
There are also some document templates that can give you a quick start about working with Docbook and XInclude, see the "Docbook 4.2 article with XInclude" that is available in the "New from templates" dialog.
Best Regards,
George
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service