Help with Merging "Nature" and "CMS 17th ed" styles
I am trying to make a custom .csl file that is based on both the "Nature" and "Chicago Manual of Style 17th edition (full note)" styles that come pre-installed with Zotero.
From the Nature style:
-----
I want in-text citations to be superscript arabic numbers (1, 2, 3). I don't want any footnotes nor endnotes. Rather, these numbers should appear in the "Bibliography" that I add to the back of my document, in numerical order. The information about each cited work should appear there. When a work is cited in multiple places in the document, it should use the same superscript number in each place in the text.
From the Chicago Manual of Style 17th edition (full note):
-----
I want all aspects of how this style formats the info in its endnotes to be used for the entries in my style's bibliography. For instance, I want this style's rules for how to list authors (full name starting with first name), what to italicize, what delimiters to use, etc.
I tried to combine these styles by taking these steps:
1. I started with the .csl file for CMS 17th ed (full note)
2. I replaced its section with the one from the "Nature" style because Nature's code block is very simple and does not call any macros.
3. I took the code that was removed from CMS17's "citation" section and added it to the section, replacing almost everything that was there
When I paste my edited style in the style editor, Zotero just reports: "Error parsing style: Error: File is not valid XML". But that is not a helpful error message because it doesn't include a line number where a problem was encountered nor does it describe the nature of the problem. I could debug my .csl file if Zotero gave helpful feedback about what line(s) to change.
Do any of you have any tips for how to do what I want to do and/or how to get helpful feedback to identify where and what the issues are in XML files?
From the Nature style:
-----
I want in-text citations to be superscript arabic numbers (1, 2, 3). I don't want any footnotes nor endnotes. Rather, these numbers should appear in the "Bibliography" that I add to the back of my document, in numerical order. The information about each cited work should appear there. When a work is cited in multiple places in the document, it should use the same superscript number in each place in the text.
From the Chicago Manual of Style 17th edition (full note):
-----
I want all aspects of how this style formats the info in its endnotes to be used for the entries in my style's bibliography. For instance, I want this style's rules for how to list authors (full name starting with first name), what to italicize, what delimiters to use, etc.
I tried to combine these styles by taking these steps:
1. I started with the .csl file for CMS 17th ed (full note)
2. I replaced its section with the one from the "Nature" style because Nature's code block is very simple and does not call any macros.
3. I took the code that was removed from CMS17's "citation" section and added it to the section, replacing almost everything that was there
When I paste my edited style in the style editor, Zotero just reports: "Error parsing style: Error: File is not valid XML". But that is not a helpful error message because it doesn't include a line number where a problem was encountered nor does it describe the nature of the problem. I could debug my .csl file if Zotero gave helpful feedback about what line(s) to change.
Do any of you have any tips for how to do what I want to do and/or how to get helpful feedback to identify where and what the issues are in XML files?
B) paste the code on pastebin.com and share with us. We'll tell you what to fix.
As you used a note style as a base, make sure that the you have class="in-text" in line 2 of your style, as well as
<category citation-format="numeric"/>
in line 12/13 or 31ish. Depends on your style.They're probably set as "note" if you didn't change it.