URLs in bibliography
Hi - Most non-web page item types include URL links in the Zotero input fields, as most everything is online in some form nowadays. I would like those URLs to then appear in the bibliography - how can this be done, using the Elsevier (Harvard) style, for example)? Or should I using the webpage item type for everything for which I want the URL to appear in the bibliography? Please share your perspectives on this!
In elsevier-harvard.csl this is handled within the access macro.
You would change it from:
<macro name="access">
<choose>
<if variable="DOI">
<text variable="DOI" prefix="https://doi.org/"/>
</if>
<else-if type="webpage post-weblog" match="any">
<group delimiter=" ">
<text value="URL"/>
<text variable="URL"/>
<group prefix="(" suffix=").">
<text term="accessed" suffix=" "/>
<date variable="accessed">
<date-part name="month" form="numeric" suffix="."/>
<date-part name="day" suffix="."/>
<date-part name="year" form="short"/>
</date>
</group>
</group>
</else-if>
</choose>
</macro>
to
<macro name="access">
<choose>
<if variable="DOI">
<text variable="DOI" prefix="https://doi.org/"/>
</if>
<else>
<group delimiter=" ">
<text value="URL"/>
<text variable="URL"/>
<group prefix="(" suffix=").">
<text term="accessed" suffix=" "/>
<date variable="accessed">
<date-part name="month" form="numeric" suffix="."/>
<date-part name="day" suffix="."/>
<date-part name="year" form="short"/>
</date>
</group>
</group>
</else>
</choose>
</macro>
First it would only if (else-if) print the URL if the item type was a website or blog. Now we have it set so it always prints the URL unless the item has a DOI.
General instructions here. Make sure to read the guide twice. ;)
https://www.zotero.org/support/dev/citation_styles/style_editing_step-by-step