Difference between revisions of "OSIS Bibles"
From CrossWire Bible Society
(→General structure) |
m (→Tools: Add iconv section) |
||
| Line 51: | Line 51: | ||
=Tools= | =Tools= | ||
| + | ==Charset conversion== | ||
| + | |||
==XML well-formed test== | ==XML well-formed test== | ||
Revision as of 09:15, 21 September 2007
Introduction
This page is for practical examples of how to encode a Bible in OSIS 2.1.1 for building a Sword module with osis2mod. It represents CrossWire's experience and best practices in creating modules.
General structure
An OSIS document is a well-formed XML document, valid according to the OSIS schema. You can find the full normative description on the OSIS Website [1].
To produce a Bible, you can use this template:
<?xml version="1.0" encoding="UTF-8"?>
<osis
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="http://www.bibletechnologies.net/2003/OSIS/namespace"
xmlns:osis="http://www.bibletechnologies.net/2003/OSIS/namespace"
xsi:schemaLocation="http://www.bibletechnologies.net/2003/OSIS/namespace http://www.bibletechnologies.net/osisCore.2.1.1.xsd">
<osisText osisIDWork="{NAME}" osisRefWork="bible" xml:lang="{LANG}" canonical="true">
<header>
{HEADER}
</header>
<div type="bookGroup">
{BODY}
</div>
</osisText>
</osis>
With the following values:
- {NAME}
- Normalized name of the Bible version (Usually 3 letters for language, 3 for translation)
- {LANG}
- ISO-639 [2] language code
- {HEADER}
- Description of the included text; see below
- {BODY}
- Text; see below
For text without any character outside ASCII, you can use US-ASCII encoding (usually for english text). For every other language, please use UTF-8. See the tools section if you need to convert.