The prefix "xi" for element "xi:include" is not bound.
Questions about XML that are not covered by the other forums should go here.
-
- Posts: 3
- Joined: Sun Mar 04, 2012 1:06 pm
The prefix "xi" for element "xi:include" is not bound.
I tried to replace <teiHeader type="corpus" xmlns:tg=".../" xml:lang="eng"> with all its information with appropriate file using xi:include in the following way: " <xi:include href="corpusHeader.xml"/>". The file corpusHeader.xml is valid, the xi:include is switched on in preferences. But the Oxygen shows the following message: The prefix "xi" for element "xi:include" is not bound. At the same time when I try to use xi:include and to convert the scheme to DTD I get the following: <!ELEMENT teiCorpus (#PCDATA)> - all other data disappears. I don't understand how to repair this problem? 

-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: The prefix "xi" for element "xi:include" is not bound.
Hello,
Are you using TEI P4 or P5?
For TEI P5 there is a Relax NG schema that already covers XInclude.
Just add the xml-model PI before the root:
You will still have to declare the XInclude namespace prefix(either on the root of the document or the element where you need it):
Regards,
Adrian
Are you using TEI P4 or P5?
For TEI P5 there is a Relax NG schema that already covers XInclude.
Just add the xml-model PI before the root:
Code: Select all
<?xml-model href="http://www.tei-c.org/release/xml/tei/custom/schema/relaxng/tei_xinclude.rng" schematypens="http://relaxng.org/ns/structure/1.0"?>
Code: Select all
xmlns:xi="http://www.w3.org/2001/XInclude"
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
-
- Posts: 1
- Joined: Wed Jul 18, 2012 7:54 pm
Re: The prefix "xi" for element "xi:include" is not bound.
Post by XiMaLaMitra »
What if one is using TEI P4? I am getting a similar error, but we have a custom made P4 DTD with extensions. Do I have to add the <xi:include> element to the places where I want to use it in the DTD itself?
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: The prefix "xi" for element "xi:include" is not bound.
Hi,
For TEI P4 + XInclude things are a lot more complicated for both validation and transformation.
The standard DTDs available for TEI P4 cannot be used to validate correctly a document with XIncluded sections. You will have to adjust the TEI P4 DTD to allow xi:include in the elements where you want to use it.
The bigger problem is that for the transformations you will have to modify the TEI P4 XSL stylesheets to work with XInclude and that's not an easy task.
If you are just starting to use XInclude, it would probably be easier to convert the TEI P4 documents to TEI P5 (Oxygen offers a transformation scenario for this) and then use the Relax NG schema (tei_xinclude.rng) mentioned in my previous post for TEI P5 + XInclude.
However, if you have a TEI P4 customization this could be more difficult since you have to also migrate that to TEI P5.
Regards,
Adrian
For TEI P4 + XInclude things are a lot more complicated for both validation and transformation.
The standard DTDs available for TEI P4 cannot be used to validate correctly a document with XIncluded sections. You will have to adjust the TEI P4 DTD to allow xi:include in the elements where you want to use it.
The bigger problem is that for the transformations you will have to modify the TEI P4 XSL stylesheets to work with XInclude and that's not an easy task.
If you are just starting to use XInclude, it would probably be easier to convert the TEI P4 documents to TEI P5 (Oxygen offers a transformation scenario for this) and then use the Relax NG schema (tei_xinclude.rng) mentioned in my previous post for TEI P5 + XInclude.
However, if you have a TEI P4 customization this could be more difficult since you have to also migrate that to TEI P5.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
-
- Posts: 2879
- Joined: Tue May 17, 2005 4:01 pm
Re: The prefix "xi" for element "xi:include" is not bound.
I'd like to correct what I said here. If the XIncludes are done right (which weren't in my tests so that's why I got the wrong impression) and you XInclude TEI snippets, then the normal TEI P4 XSL stylesheets should work correctly with XInclude because the XIncludes will be expanded before the transformation.adrian wrote:The bigger problem is that for the transformations you will have to modify the TEI P4 XSL stylesheets to work with XInclude and that's not an easy task.
I still think TEI P5 would be a better option with XInclude.
Regards,
Adrian
Adrian Buza
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Return to “General XML Questions”
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