Modifying word plug-in: Using journal abbreviation instead of publication name


Is there a way to modify Zotero's word plug in? Currently, when I use the Harvard style for my bibliography in Word, Zotero uses publication name instead of journal abbreviation when it creates a reference. Normally, that would be ok except that Pub Med often stores more information than necessary in their publication name field. For example, when I want to reference AIDS the information in publication name looks like: AIDS (London, England). The information in the journal abbreviation is: AIDS. The latter is correct and all I need for the reference. Can I change the fields that Zotero looks at when creating a reference so that the journal abbreviation field is used to provide information about which journal the article came from?

  • yes, but the change has nothing to do with the word plugin, what you want to change is the style
    Open the Zotero Test Pane
    select a citation from a journal in Zotero.
    Select Harvard stlyle from the drop down menu

    Look at the (xml) code you see in the upper half of your split screen.
    Find the line:
    <text variable="container-title" font-style="italic"/>
    and change it to
    <text variable="container-title" form="short" font-style="italic"/>
    - so you're telling Zotero to use the short form of the "container" (in this case journal) publication. You'll see the change immediately below in the bibliography.

    Now you need rename your new style.
    Go all the way to the top of the code and find the two lines
    <title>Harvard Reference format 1 (Author-Date)</title>
    change them both to something like Harvard-Journal Short and
    (to the experts: what makes sense tu put in the id field?)

    Last step - how do you get this new style into Zotero?
    You select the entire code and paste it into a text editor (NOT Word or Wordpad. On windows use notepad).
    Then you save the file as HarvardJS.csl - the important part here is the .csl - and drag it to Firefox, which will automatically install it in Zotero. Done.
  • Thanks for the help. It worked perfectly!
  • I tried these same steps, when I drag the new notepad file named XXXXX.csl.txt into Firefox, it does not prompt me to install the new citation format (as it does when I dragged the original XXXXX.csl.htm file in). Is the issue that it has the .txt extension? I didn't add this, Notepad did.
  • Remove the .txt extension.
  • I have named it "sbl-fullnote-bibliographyShortJournalTitle.csl" inside Notepad, but its real name is "sbl-fullnote-bibliographyShortJournalTitle.csl.txt" when I put it into Firefox.

    How can I get rid of the .txt? I have tried renaming it in its properties. No go.
  • Aha! I unselected the hide file extension, and then could manually change it, and popped it into Firefox, and it installed!


  • Is <text variable="container-title" form="short"/> still working for people? I can't get it to work for me, using Zotero 2.1b7 and this macro to set the format:

    <macro name="container-title">
    <if type="article-journal">
    <text variable="container-title" form="short" strip-periods="true"/>
    <text variable="container-title" form="short"/>
  • That works fine in the processor outside of Zotero, and the relevant code hasn't changed in quite a long time. The name of the macro might be confusing in your CSL. Is it possible you're accidentally calling the data with <text variable="container-title"/>, and not <text macro="container-title"/>?
  • edited March 7, 2011
    No, I carefully changed it. But before I wrote the macro, the code called for just this:
    <text variable="container-title" form="short"/>

    I adapted this style from the Oecologia style (upgraded to CSL 1.0 and tweaked a bit). If you just use Oecologia style -- which has that code with the "short" form container title -- the journal name comes out long, not short.
  • edited March 7, 2011
    1) Just to be sure, did you check whether the "Journal Abbr" field of your cited items really contains the journal abbreviation and not the full journal name?

    2) Please post your style to (instructions are available at
  • My name is Ms. Massive Dolt. I added the abbreviation for my test item in one of my group libraries, but not in the one I actually used for the document. Or so I think at least... now that I corrected that, the original style is working.
  • Understandable at this stage of the new client's development. Things will get easier as it earns your trust.
  • edited April 18, 2011
    Thanks for this helpful post. I've followed these steps to the letter, but unfortunately the journal title continues to be the full one instead of the abbreviated one (to be sure, I've included the abbreviation of the journal in the "journal abbr" field). Any troubleshooting suggestions?

    Thanks in advance!
  • test this in the Vancouver or Nature style. If those abbreviate correctly, the problem is with your style. If they don't, the problem is with your data.

    We can help you troubleshoot styles if you post them as public gists to and put a link here. If the problem is your data that's more complicated.
  • edited April 18, 2011
    Thanks. Here is the link to the public gist:
  • What exactly is the output you want? A quick look suggest that you'd get journal abbreviations in the footnotes, but not in the bibliography. Is that not what you're seeing?
  • Thanks for this. Very helpful! I would like journal abbreviations both in the footnotes and in the bibliography, if possible.

    Also, any tips on adding a 'series abbr' field, so that I can use abbreviated series titles (i.e. for book series) in both the footnotes and bibliography?

  • Find
    <text variable="container-title" font-style="italic"/>
    in the container-title macro
    (it should be line 327 or very close)
    and add form="short" as in the "container-title-note" macro.

    Series abbreviations are currently not supported in Zotero, though if I understand correctly, once they are, they can be used by csl without any problems
    ( using form="short" on the collection-title variable)
Sign In or Register to comment.