quotes and parenthese help with csl code

Hello,

I am very much a novice in csl and I'd appreciate some help with editing csl code to obtain the right style.

At the moment I get citations with single quotes and a date not in parentheses for journal citations, e.g.

Roger Mourad, ‘After Foucault A New form of Right’, Philosophy & social criticism, Vol. 29, no. 4, 2003, pp. 451–481.

1)what do I need to change to render the single quotes to double quotes?

2) How do I add parentheses to the date without a prior comma

e.g. Roger Mourad, ‘After Foucault A New form of Right’, Philosophy & social criticism, Vol. 29, No. 4 (2003), pp. 451–481.

Also,

3) In the Zotero reference pane [Zotero Standalone] I get this when I test style preview with cite position subsequent:

Individual Citations
[CSL STYLE ERROR: reference with no printed form.].

Could you advise how to fix this pls?

Warmest regards,

Louiza Odysseos
  • we'd have to see the style. Post to gist.github.com, create a puplic gist and post the link here.
  • Thanks, here it is:

    https://gist.github.com/anonymous/a15c4eab7bf4720e5c77
  • 1) changing default-locale to "en-US" at the top of the style would work, though that also places punctuation into the quotation marks. A Hybrid of the two is a bit tricky.

    2) the year is in
    <text macro="date"/> and you get the comma because it's in a group with delimiter=", " -- how to change that depends on how it's supposed to look in other format than journal articles, but

    <group delimiter=" ">
    <text macro="volref"/>
    <text macro="date" prefix="(" suffix=")"/>
    </group>
    would work.

    3) you rely on a macro "contributors-short" that doesn't actually exist. I assume you want to change that to author-short and then change the part after the disambiguate test a couple of lines further down to title-short
  • My confusion arises from the absence of any <if-type=article_journal> specification. so the only date I can find is

    </macro>
    <macro name="date">
    <date variable="issued">
    <date-part name="month" suffix=" "/>
    <date-part name="year"/>
    </date>
    </macro>

    But it is right after publisher code, which makes me think it is for primarily for books. How/Where do I add it to this? Would this work?

    </macro>
    <macro name="date">
    <date variable="issued">
    <date-part name="month" suffix=" "/>
    <date-part name="year"/>
    <group delimiter=" ">
    <text macro="volref"/>
    <text macro="date" prefix="(" suffix=")"/>
    </group>
    </date>
    </macro>
  • right, good styles are written in a way that makes as little reference as possible to specific item types and only uses things like if type="article-journal" (sic!) where absolutely necessary, which may or may not be the case here.

    The code I suggest above would replace
    <text macro="volref"/>
    <text macro="date"/>
    in lines 193/194 of the style you posted.
  • Thanks ever so much! That worked very well.
  • May I trouble you with another query?

    I need to have the ability to include a page number with Ibid. and op. cit. where the page no in a subsequent citation differs.

    Here is the style as it stands now:

    https://gist.github.com/anonymous/070c330ffbeb189bde37

    Thanks ever so much.
  • you want to use <text macro="pageref"/> instead of the
    <text macro="point-locators-subsequent"/> (occurring at least twice) that isn't defined in the style.

    Every time you have <text macro="XYZ"> you need to make sure that there actually is such a macro, defined by <macro name="XYZ">
  • Thanks, it has been an education!
  • Hello,

    I have another minor query:

    The style which I am working with has a comma following the title and no matter how much I tinker with delimiters I cannot get rid of it.

    e.g. Mitchell Dean and Barry Hindess, Governing Australia: Studies in Contemporary Rationalities of Government, (Cambridge University Press, 1998).

    https://gist.github.com/anonymous/1f1eab1661d642723315

    Thanks in advance for your advice!
  • If the number of volumes is included, should there be a comma after "vols," before the open-parens? Or should there never be a comma immediately before the open-parens?
  • No such example is given in instructions for authors so I can only assume never a comma before the open-parens.

    thanks
  • Alos in my tinkering and ignorance I have generated more problems.

    My book citations with page references now look like this:

    Michel Foucault, Security, Territory, Population: Lectures at the Collège de France, 1977-1978, (Basingstoke: Palgrave Macmillan, 2007), . p. 201.

    and I need to get rid of the extra period following the close-parens ),

    Moreover, I have somehow managed to render the ibid. with page number without a space and comma after ibid.

    Please help.

    Ibid.p. 28.
  • edited May 5, 2015
    Here is a copy that fixes that particular issue:

    https://gist.githubusercontent.com/fbennett/6df744e3d6dbd4797227/raw/cbf6aa918f3476c04856107f1b0c7b88164ce012/oxford-art-journal.csl

    It needed an extra wrapping group (inside the condition) to set the delimiter between the two (comma-delimited) blocks to a space.

    There are a bunch of other problems with the style, though. (If you have a GitHub account [or sign up for one], I can send you a link to a dynamic previewer that may help you sort through the issues quickly.)
  • I see that you have spotted the problems. :-)

    The content of the "ibid" and "ibid-with-locator" conditions should also be switched - it is trying to render bare "Ibid." on the ibid-with-locator condition, instead of the other way around.
  • Please do, my Github account is OdysseosL. Thanks.
  • I've sent a private message with the URL. If you don't receive mail, you can pick it up via the "Inbox" link at the top of this page.

    (There's no cause for secrecy; the tool is just new, and there may be bugs.)
Sign In or Register to comment.