TEI export

Good morning,
I'd like to create a master bibliography for my project with Zotero, but when I export it into xml TEI, all the elements are diplayed on one single (and very long) line.
How can I solve this issue?
Many thanks for your help. Regards,
Alessio.
  • Dear Alessio,

    Most TEI editors include an option to format and indent the contents of .xml files. I use Oxygen, and 'Format and Indent' may be found under 'Tools'. Clicking this should solve your problem.

    Best wishes,

    James
  • For a quick reformat of a not too large file, https://www.freeformatter.com/xml-formatter.html will likely do. If you need to do this often, and you don't mind/prefer the command line, xmllint --format will do it.
  • TEI export for record type "Manuscript" (and other types as well) does NOT include the following fields: Author, Type, # of pages, Language, Archive, Loc. in Archive, Library Catalog, Rights, Extra, Attached link to URL. Could that be changed?
  • bwb
    edited September 28, 2020
    Moreover TEI export does not include the abstract filed
  • If author isn't included, that'd be a bug. For all the others, I don't see how they'd be part of the biblStruct element in TEI that Zotero exports to
  • Dear all,
    I have some questions regarding the export to TEI:

    - some weeks ago it was possible to export a library to TEI and create single documents for every entry. Now this seems not possible anymore. Can someone tell me why? Has there been a change in the export settings? Are export-options stable or may they change?
    - in my export the TEI file does not validate correctly, the following errors are shown:

    a) element "edition" not allowed here; expected the element end-tag or element "biblScope", "extent" or "imprint"
    b) element "extent" not allowed yet; missing required element "imprint"
    c) element "author" not allowed here; expected the element end-tag or element "biblScope", "extent" or "imprint"

    Is there a bug in the export to TEI?

    Many thanks for your help
    Sulamith
  • 1. Nothing relevant in the TEI export has changed for years. My best guess is you're remembering this incorrectly - Zotero export has always produced one file for a single export operation.
    More generally, export does change, but typically for extensions or bugfixes.

    2. How exactly are you validating TEI? We've had no other reports of this, again, for multiple years. And are those consistent errors or limited to a specific item?
  • Using Zotero 6.0.21 I can add some issues in this context:

    A) Right-Click/Export Library…
    Format: TEI
    All options checked (Export Notes, Export Tags, Generate XML IDs, Full TEI Document, Export Collections)

    This returns a well-formed TEI, but it is both not valid against the TEI schema and missing all the items except for a tei:listBibl for each collection that contains nothing but the collection name as tei:title.

    B) Select all items in the library and then: Right Click/Export Items…
    Format: TEI
    All options checked (see above)

    This returns a well-formed TEI containing a single tei:listBibl with the same number of tei:biblStruct as my test library contained. Nevertheless, it is still not valid against the TEI schema, but in my case, it's only 16 errors reported in a library with 455 entries. The errors reported in my case, can be reduced to a single error, as all other errors reported a a consequence of it:
    * tei:extent does not appear in the right location; in tei:monogr it appears as first-child instead of last-child
  • is there an online validator for TEI somewhere?
    B) can probably be fixed very easily and would seem the more important one to fix (since it serves as a viable alternative to A)
  • I usually do offline validation which could also be done in a bash script but if you're looking for an online service a quick google search returned https://teibyexample.org/tools/TBEvalidator.htm which also reports the wrong tei:extent
Sign In or Register to comment.