Importing marked-up citation info from raw text/HTML file

I frequently find myself at the campus library looking up references on their computers. I use portable Firefox on my thumb drive with Zotero, but our library network has significant problems with user thumb drives and the IT staff has been unable to resolve them, so that's pretty much useless. Ergo, when I go back home I've been tediously looking up the references all over again in order to create Zotero entries.

However, the library does have the capability to email HTML or text files of marked-up references in MARC, end-note, and refworks formats. So I tell the library computer to email me a reference, and here's an example of what I get in the email if I choose End-note/Refworks:

%A Bowman, James, 1948-
%T Honor : a history
%C New York :
%I Encounter Books,
%7 1st ed.
%8 2006.
%@ 1594031428
%@ 9781594031427
%1 BJ1533.H8 B69 2006
%K Honor.
%O "From the earliest records of human civilization until the dawn of the twentieth
century, and in widely separated cultures throughout the world, the story of honor
was inseparable from the story of mankind.".

Here's a MARC example:

LEADER 00000pam 22005294a 4500
001 63178867
003 OCoLC
005 20060521102102.5
008 060118s2006 nyu b 001 0 eng
010 2006001840
020 1594031428
024 3 9781594031427
040 DLC|cDLC|dBAKER|dC#P|dOrLoB-B
042 pcc
050 00 BJ1533.H8|bB69 2006
082 00 179/.9|222
100 1 Bowman, James,|d1948-
245 10 Honor :|ba history /|cJames Bowman.
250 1st ed.
260 New York :|bEncounter Books,|c2006.
300 381 p. ;|c24 cm.
504 Includes bibliographical references (p. 329-359) and
index.
520 1 "From the earliest records of human civilization until the
dawn of the twentieth century, and in widely separated
cultures throughout the world, the story of honor was
inseparable from the story of mankind. Today, an
acquaintance with the concept of honor is indispensable to
understanding the culture of the Islamic world and its
sense of grievance against the West, where honor has been
disregarded or actively despised for three-quarters of a
century.".

It seems to me that Zotero must have the functionality to parse marked-up text like this--that's essentially what it does when it creates a citation from a library's online record, no? However, when I save the email message with such marked-up entries (as an HTML file or a text file) on my hard disk and then try to import it, Zotero says it doesn't have a site translator and won't proceed.

Apparently End-note and Refworks can import marked-up references from HTML or text files like this (I've never used either, but since the library creates marked-up references for these programs, they must be able to import citations this way). So Zotero should also be able to do it. So how do I go about it? Or does the file have to have some kind of code at the beginning to signal Zotero that it should parse the text and create references? If so, can I just copy that code from somewhere and paste it at the top of such files, so Zotero can import the references?

Thanks,
Mike300
  • Save the contents of the email to a text file & import into zotero (gear->import & select the file).
  • I had done that before with MARC records and it didn't work. Since you said to do it, I thought maybe Zotero couldn't do this with MARC, so I tried the End-note/Refworks format and it worked.

    But why is that? Surely Zotero is parsing MARC records when it imports directly from a library catalog. Why can't it handle them from a text file?

    --Mike
  • Zotero cannot "import" files in all of the formats that it can "translate" from web pages.

    However, it should be able to import MARC-formatted files. Try saving a MARC-formatted text file with a ".MARC" extension & selecting the "MARC" file type when importing it. If you have problems, you might be able to provide a minimum failing example.
  • edited September 29, 2008
    OK, I did that, ASCII text file with extension changed to *.marc & selecting MARC type within Zotero's importation dialog, and no dice. Just to make sure Zotero wasn't choking on too many items, I cut a single item and put it in its own individual text file and went through the same process with that as well, and it still says, "No translator could be found for the given file".

    Here's the record I singled out for the individual experiment (I'd just attach the text file, but I don't see a way to add attachments on Zotero forums). Maybe there's something idiosyncratic about the way my campus library outputs MARC records (by the way, I also tried stripping off that first LEADER line, but it made no difference):

    LEADER 00000pam 2200409 a 4500
    003 DLC
    005 20040927151526.7
    008 031024s2004 nju b 001 0 eng
    010 2003063294
    020 0691117144 (alk. paper)
    020 0691117152 (pbk. : alk. paper)
    040 DLC|cDLC|dOrLoB|dOrLoB-B
    042 pcc
    050 00 JA78|b.P54 2004
    082 00 320/.01|222
    100 1 Pierson, Paul.
    245 10 Politics in time :|bhistory, institutions, and social
    analysis /|cPaul Pierson.
    260 Princeton, N.J. ;|aOxford :|bPrinceton University Press,
    |cc2004.
    300 xii, 196 p. :|bill. ;|c24 cm.
    504 Includes bibliographical references and index.
    650 0 Political science.
    650 0 Time|xSociological aspects.
    902 040927AB0701
    910 arp
  • Zotero's MARC import supports only standard binary MARC 21 records (see the specification at http://www.loc.gov/marc/specifications/specrecstruc.html). These binary records are not human-readable. What you have here looks like an ASCII serialization of a binary record. While it might be possible for Zotero to read these records, this might be difficult since, as far as I know, there is no cross-vendor specification for ASCII serialized MARC records. (While the field codes are obviously standard MARC 21 codes, the characters used to delimit fields and subfields likely vary between catalog software.) However, Zotero should be able to import the EndNoteĀ® file just fine.
  • OK, thanks for clearing that up.

    > However, Zotero should be able to import the EndNoteĀ® file just fine.

    Yes, it did.

    Thanks,
    Mike
Sign In or Register to comment.