Open rmzelle opened 7 years ago
I guess the first step would be using some regex to identify how many styles print the "URL" variable, and determine how many of those do and do not print this conditionally based on a populated "page" field. For those without a conditional, we'll have to check the style guides to see if one is needed.
During that effort, I think it would be a good and efficient idea to make the URL code construct a DOI-based URL if available and then only print the URL field if no DOI is available.
There currently are 1556 styles referring to the URL variable. Of these, there are four common calling structures:
internet
term in brackets to the title when URL is present (196 styles)For 1 and 2, nothing needs to change. For 3, I think it is reasonable to assume that the intended behavior is to include the URL if no page numbers are present (we have frequent complaints on the Zotero forums about this word being added). For 4, we could check style guides, but this appears to be a fairly small number of styles that I don't think it would be too disruptive to remove the option before addressing it. So the major step to take, I think, would be to adjust the 196 styles including the internet
term if URL is present.
Also, many of these styles using internet
already suppress it for articles, chapters, and conference papers.
I'm shocked that 4. is a fairly small number of styles -- are you sure? I thought that'd be a huge number and our biggest problem.
Okay, I finished running a bunch of regex to dig into the four types of styles that print URL
. Results:
I only checked for the presence of if type="web
or if type="post
for 2, so those should be verified that URL is actually handled dependent on them.
So, 4 is about half of the styles using URL
. There are probably a few more tricks to whittle down the list (e.g., any styles with APA as a template).
I think a good first step would be to start with the Vancouver styles (and the versions of them from the major publishers).
I've made a spreadsheet (ala @POBrien333's tracker for style requests) to track the status of updating/verifying styles: https://docs.google.com/spreadsheets/d/1Yn7P0D4hZNvdq-YRR08oJwczNTrcycLDF0FMhTM7mAQ/edit?usp=sharing
This issue hasn't seen any activity in the past 30 days. It will be automatically closed if no further activity occurs in the next two weeks.
Dan Stillman indicated he wouldn't mind removing the "Include URLs of paper articles in references" toggle in the "Styles" > "Cite" tab of the Zotero preferences (see https://forums.zotero.org/discussion/comment/269136/#Comment_269136 and later comments). It was added back in 2008, and is unchecked by default (https://github.com/zotero/zotero/blob/dcd1da70af223f41aa1b827387d0cc69ef828e69/defaults/preferences/zotero.js#L111). So by default, Zotero overrides the behavior specified in styles by suppressing the "URL" CSL variable when the "page" CSL variable isn't empty for the "article-journal", "article-newspaper", and "article-magazine" CSL item types (https://github.com/zotero/zotero/blob/36b6722c5ca4274e21c7679aad83be3d660a471b/chrome/content/zotero/xpcom/cite.js#L537):
@adam3smith and I rather see the toggle (and its effects) removed. To minimize disruption, we probably first need to put the logic into styles where necessary.