{"id":883,"date":"2021-02-02T14:24:14","date_gmt":"2021-02-02T13:24:14","guid":{"rendered":"http:\/\/thebarumfabula.usc.es\/?post_type=docs&#038;p=883"},"modified":"2021-02-28T14:27:35","modified_gmt":"2021-02-28T13:27:35","slug":"estructura-de-un-documento-tei-xml","status":"publish","type":"docs","link":"https:\/\/thebarumfabula.usc.es\/en\/guidelines\/primeros-pasos\/estructura-de-un-documento-tei-xml\/","title":{"rendered":"Structure of a TEI-XML document"},"content":{"rendered":"<p>A TEI XML document is a collection of tags nested within each other with a very clear and defined hierarchical structure. The entire content of a TEI document is framed by the tag <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;TEI&gt;<\/code>:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"xml\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">&lt;TEI> \u2026\u2026 &lt;\/TEI><\/pre>\n\n\n\n<p>It is the only tag that is written entirely in capital letters. The rest of the tags will always be in lower case, or with an internal capital letter if the tag is an abbreviation of two words. The format of each one must always be respected.<\/p>\n\n\n\n<p>Every TEI XML is always divided into two main parts, the header, or <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;teiHeader><\/code> and the text itself, or <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text><\/code>:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"xml\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">&lt;TEI>\n\n\t&lt;teiHeader>\n\t\t... Contenidos de la cabecera del documento ...\n\t&lt;\/teiHeader>\n\n\t&lt;text>\n\t \t ... El documento ....\n\t&lt;\/text>\n\n&lt;\/TEI><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">&lt;teiHeader&gt;<\/h2>\n\n\n\n<p>For full information and instructions on how to complete this section, see the chapter on <a href=\"http:\/\/thebarumfabula.usc.es\/en\/guidelines\/cabecera-de-cada-documento-teiheader\/\" data-type=\"docs\" data-id=\"1198\">&lt;teiHeader&gt;<\/a>.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">&lt;text&gt;<\/h2>\n\n\n\n<p>Since our editions contain original texts aligned with one or more translations in parallel, each of these versions of the text is itself a <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code>. And for a single XML document to contain several <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code> it is necessary to group them with the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;group&gt;<\/code>tag. This allows you to add as many translations as you wish, without limit.<\/p>\n\n\n\n<p>Thus, the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code> of all our editions has the following structure:<\/p>\n\n\n\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"xml\" data-enlighter-theme=\"\" data-enlighter-highlight=\"\" data-enlighter-linenumbers=\"\" data-enlighter-lineoffset=\"\" data-enlighter-title=\"\" data-enlighter-group=\"\">&lt;text&gt;\n\t&lt;group&gt;\n\t\t&lt;text type=&quot;source&quot; xml:lang=&quot;la&quot;&gt;\n\t\t\t&lt;body&gt;\n\t\t\t\t&hellip; Contents of the critical edition: original text and critical apparatus &hellip;\n\t\t\t&lt;\/body&gt;\n\t\t&lt;\/text&gt;\n\t\t&lt;text type=&quot;translation&quot; xml:lang=&quot;es&quot;&gt;\n\t\t\t&lt;body&gt;\n\t\t\t\t&hellip; Contents of the Spanish parallel translation, with notes as commentary &hellip;\n\t\t\t&lt;\/body&gt;\n\t\t&lt;\/text&gt;\n\t\t&lt;text type=&quot;translation&quot; xml:lang=&quot;en&quot;&gt;\n\t\t\t&lt;body&gt;\n\t\t\t\t&hellip; Contents of the English parallel translation, with notes as commentary &hellip;\n\t\t\t&lt;\/body&gt;\n\t\t&lt;\/text&gt;\n\t&lt;\/group&gt;\n&lt;\/text&gt;\n<\/pre>\n\n\n\n<p>Note that there are two attributes that must obligatorily be carried by each of the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code> within the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;group&gt;<\/code>:<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li><code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">@type<\/code>: there are two possibilities: <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">\"source\"<\/code> if it is a <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code> that contains the original text and its critical apparatus, and <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">\"translation\"<\/code>, if it contains the translations.<\/li><li><code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">@xml:lang<\/code>: we need to indicate the language in which each of these <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code>is written. See the chapter <a href=\"http:\/\/thebarumfabula.usc.es\/en\/guidelines\/primeros-pasos\/etiquetas-tei-xml\/los-atributos-xmlid-y-xmllang\/\" data-type=\"docs\" data-id=\"1128\">@xml:lang<\/a> for all the language codes available.<\/li><\/ul>\n\n\n\n<h3 class=\"wp-block-heading\">&lt;body&gt;<\/h3>\n\n\n\n<p>Each of the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;text&gt;<\/code> that comprise the root <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;group&gt;<\/code> of our editions carries a single tag <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;body&gt;<\/code>, the <em>body<\/em> of the document.<\/p>\n\n\n\n<p>The <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;body&gt;<\/code> contains the original text, the aparatus, the translations, and the notes that we wish to add to make the commentary. <\/p>\n\n\n\n<p>Each work will have its own internal structure within its <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;body&gt;<\/code>: an epic poem does not have the same structure as a tragedy, or a work of prose. To see the different structures of each type of text, <a href=\"http:\/\/thebarumfabula.usc.es\/en\/guidelines\/divisiones-div\/\" data-type=\"docs\" data-id=\"1522\">cf. la etiqueta &lt;div&gt; y sus subcap&iacute;tulos<\/a>.<\/p>\n\n\n\n<p>To learn which tags can be used within the <code data-enlighter-language=\"xml\" class=\"EnlighterJSRAW\">&lt;body&gt;<\/code> in order to compose editions, see the chapter <a href=\"http:\/\/thebarumfabula.usc.es\/en\/guidelines\/etiquetas-importantes\/\" data-type=\"docs\" data-id=\"1338\">Important Tags<\/a>.<\/p>\n\n\n\n<p>On how to tag original texts and translations in an aligned way, see the chapter <a href=\"http:\/\/thebarumfabula.usc.es\/en\/guidelines\/alineamiento-de-texto-original-y-traducciones\/\" data-type=\"docs\" data-id=\"1165\">Alignment of original texts and translations<\/a>.<\/p>","protected":false},"featured_media":0,"parent":1073,"menu_order":2,"comment_status":"open","ping_status":"closed","template":"","doc_tag":[],"class_list":["post-883","docs","type-docs","status-publish","hentry"],"comment_count":0,"_links":{"self":[{"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs\/883","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/types\/docs"}],"replies":[{"embeddable":true,"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/comments?post=883"}],"version-history":[{"count":47,"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs\/883\/revisions"}],"predecessor-version":[{"id":2002,"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs\/883\/revisions\/2002"}],"up":[{"embeddable":true,"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs\/1073"}],"prev":[{"title":"TEI-XML Tags","link":"https:\/\/thebarumfabula.usc.es\/en\/guidelines\/primeros-pasos\/etiquetas-tei-xml\/","href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/docs\/1080"}],"wp:attachment":[{"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/media?parent=883"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/thebarumfabula.usc.es\/en\/wp-json\/wp\/v2\/doc_tag?post=883"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}