Easy CSL Question

I'm simply trying to Frenchify APA 6th Edition CSL. One of the few parts which I must modify is with Web Pages. Here are the few lines referring to it:

<if variable="DOI">
<text variable="DOI" prefix="doi:"/>
</if>
<else>
<choose>
<if type="webpage">
<group delimiter=" ">
<text term="retrieved" text-case="capitalize-first" suffix=" "/>
<group>
<date variable="accessed" suffix=", ">
<date-part name="month" suffix=" "/>
<date-part name="day" suffix=", "/>
<date-part name="year"/>
</date>
<text variable="year-suffix"/>
</group>
<text term="from"/>
<text variable="URL"/>
</group>
</if>

To make a short question: I must change "Retrieved from" to "Récupéré de", but after changing terms and saving file, when I import a bibliography in MS-Word, it doesn't work... No terms appear at all... What Am I missing??

Thank you!

Vincent
«1
  • I am not sure how CSL localization works, but you can help the people that do to help you by posting the entire CSL file after your modification online:

    http://pastepad.net/
  • You are suggesting I post the whole CSL file here?

    Why are you referring to http://pastepad.net/ ?
  • Copy paste the content of the whole CSL file there so that people can take a look at your modification to see why it does not work.
  • edited December 22, 2011
    In the second line which looks like:
    <style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0"
    demote-non-dropping-particle="never">

    add default-locale="fr-FR"
    <style xmlns="http://purl.org/net/xbiblio/csl" class="in-text" version="1.0"
    demote-non-dropping-particle="never" default-locale="fr-FR">


    Source here.
  • Hi Gracile,

    I added that line, but it didn't change anything.

    Here is my script... I pasted it in pastepad and then copie-paste it here, but it was too long... How do I use pastepad?


    What is wrong??

    Thank you

    Vincent
  • Sorry, I meant to write

    http://pastebin.com/

    pastepad does not share pastes with others.
  • edited December 22, 2011
    I created the pastebin, should I apply an highlight style to ease your reading?
  • I do not think that that is necessary, but if you want to, use XML style if available.
  • What's the url of your pastebin?
  • Here it is: http://pastebin.com/CG1kZKSa

    Hope it might help diagnose the trouble...

    Just to further explain: I only modified terms that were in english for french terms. Thus, references written as <text term=>

    example: <text term="récupéré" text-case="capitalize-first" suffix=" "/>

    I also added Gracile suggestion at the beggining. It's all I did so far...

    Thank you for your help

    Vincent
  • Just to mention... I'm testing with Mendeley, just in case it might be the problem... I can use Zotero if there is nothing wrong with the CSL file...
  • Just to further explain: I only modified terms that were in english for french terms. Thus, references written as <text term=>

    example: <text term="récupéré" text-case="capitalize-first" suffix=" "/>


    That's the problem. You don't have to translate "terms" as they are already translated (that what is called "csl locales"). You only have to change the second line as I wrote before: everything should be automatic then.
  • But I did also try only modifying the top string adding

    default-locale="fr-FR"

    But it didn't work... Let me try it again...

    be back in 2 minuts
  • I'm in a hurry so I can't explain here but read that: http://citationstyles.org/downloads/specification.html#localized-terms

    When you use "text term", you must use the "official" terms names. It's like "text variable" variable...
  • Vincent: This forum is for Zotero support. You need to contact Mendeley for Mendeley support. If you can reproduce a problem with Zotero, we're happy to help you here.
  • but also - my experience with Mendeley's implementation of CSL is that it's consistently buggy, so if things just aren't working the way the should that may very well be a Mendeley issue - ideally you would test this on Zotero - if it doesn't work there we can help you. If it does work in Zotero but not Mendeley it's a Mendeley bug.
  • Here is the link with only the first line modified with locale-fr-FR http://pastebin.com/hJbj8DMD
  • En français: l'intérêt des "term", c'est qu'ils sont "localisés", c'est à dire que zotero connait leur traduction en différentes langues que l'auteur d'un style peut spécifier en début de style. Ce que je vous ai "proposé".

    Si l'on veut changer une traduction, mais ce n'est pas votre problème, il faut utiliser quelque chose comme:

    <locale xml:lang="fr">
    <terms>
    <term name="in">in</term>
    <term name="page" form="short">
    <single>p.</single>
    <multiple>pp.</multiple>
    </term>
    </terms>
    </locale>


    Je m'en vais mais quelqu'un (ou moi plus tard) vous aidera...
  • You're absolutely right. I was referred here by Richard Karnesky, this is why I tried to solve my problem in this forum. I tought CSL problems could be solved either on Zotero or Mendeley forums... This is why I'm here...

    Thank you all, this is probably a Mendeley issue...

    Vincent
  • just to confirm - the style works with Zotero, I get e.g.

    How Airplanes Fly. (s. d.). Consulté décembre 22, 2011, de http://www.allstar.fiu.edu/aero/airflylvl3.htm

    i.e. French terms (you'd have to redefine Consulté to Recuperé - the links provided by Gracile tell you how.)
  • Hi Adamsmith,

    since you succeded to generate a french bibliography, then it confirms the problem is with Mendeley Desktop + Ms-Word plugin. I posted that problem on Mendeley Research Networks. I hope comunity there is as effective and helpful as with Zotero's.

    Thank you all,

    Vincent
  • I'm trying to create a CSL file that will be OK with Zotero, so just another question, should I modify line 34-35 changing "en" to "fr"

    </info>
    <locale xml:lang="fr">
    <terms>

    or just modify the first line as suggested by Gracile ??
    What did you do on your side adamsmith?
  • I just took the style you posted - you shouldn't modify line 34-35, but they give you a template for how to define terms for the French version - i.e. you could put in another section starting with
    <locale xml:lang="fr">
    <terms>
    to define retrieved as recupere instead of consulte.

    (you can also delete l. 32-39 - if "fr" is selected as the default locale, terms define for "en" won't do anything).
  • edited December 22, 2011
    Lines 32-37 are useless for you. They redefine the "translator" term for the English version.

    But if you need to redefine French terms, something like that would be useful:

    <locale xml:lang="fr">
    <terms>
    <term name="in">Mot à la place de in, ex: dans</term>
    <term name="page" form="short">
    <single>p.</single>
    <multiple>pp.</multiple>
    </term>
    </terms>
    </locale>


    [Edit: same as adamsmith...]
  • Thank you adamsith and Gracile.

    So based on Gracile's post, I understand that the redefined term goes in-between the hooks: >here<


    <locale xml:lang="fr">
    <terms>
    <term name="in">dans</term>
    <term name="page" form="short">
    <single>p.</single>
    <multiple>pp.</multiple>
    </term>
    </terms>
    </locale>

    As example, if I want to redefine "in" with "dans", I would simply specify it as suggested in this post?
  • Yes my example redefines "in" with "dans" and "page" with "p." for a single page ("page 5") and "pp." for a page range ("pages 5-7").
    You should use that only if you're not happy with default-locale="fr-FR" (which should make most of the translations)
  • edited December 22, 2011
    Since I have received no help on Mendeley forum yet, I tried your tweaking for applying changes to terms, and it works! I don't know how Mendeley Desktop runs its relation to the remote server, but applying chages in the header didn't change a thing, but modifying terms has worked.

    I only have one problem left, it displays month with first letter capitalized. How can I make it lower case?

    Please look at my script: http://pastebin.com/cnbwKLwx line 147

    Thank you
  • I only have one problem left, it displays month with first letter capitalized. How can I make it lower case?
    What is "it" here? Zotero or Mendeley?

    Again, this forum supports Zotero users. It's not a general-purpose CSL forum. We can't spend time here making up for Mendeley's lack of support.
  • in Zotero they are lowercase. You can usually change casing using text-case="lowercase" as in
    <date-part prefix=", " name="month" text-case="lowercase"/>

    @Dan - I understand the issue, but we don't really have a separate csl forum and for people like Rintze, Frank and me it would be a lot of work to cater to another forum - so yes, if we handle csl questions here that will include some by Mendeley (Papers, Quigga and whatelsedoiknow) but Zotero gets the benefit (at least I hope you guys see it as a) of us hanging around here and also trying to help out on other issues.
  • adamsmith: It's your (generously contributed) time, but I still think that problems here should be reported in the context of output from Zotero, if for no other reason than that you guys shouldn't be expected to spend time dealing with bugs in other software.

    (There are other reasons, of course: Zotero users are much more likely to contribute back ideas, bug reports, support for other users, publicity, etc. Mendeley is a for-profit company—it's not clear to me why they can't provide adequate support for their own users. If their userbase grew by a million people, should all of those new users still rely on the three of you for CSL support?)
This discussion has been closed.