Skip to content
This repository has been archived by the owner on Apr 30, 2021. It is now read-only.

Link prefix to DOI when it forms a URL #107

Closed
adunning opened this issue Mar 3, 2015 · 2 comments
Closed

Link prefix to DOI when it forms a URL #107

adunning opened this issue Mar 3, 2015 · 2 comments

Comments

@adunning
Copy link
Contributor

adunning commented Mar 3, 2015

Certain styles (e.g. MHRA, APA) write the DOI prefix as a URL, putting http://dx.doi.org/ or http://doi.org/ (as opposed to Chicago, which simply calls for doi:). This is not written as part of a link when it is run through pandoc-citeproc. If we take this as an example:

pandoc -F pandoc-citeproc << EOT

---
references:
- DOI: 10.1017/CBO9781139923279
  id: wakelin:2014scribal
csl: modern-humanities-research-association-author-date.csl
...

@wakelin:2014scribal

EOT

This is the result:

<p><span class="citation">([n.d.])</span></p>
<div class="references">
<p>[n.d.]. &lt;http://dx.doi.org/<a href="http://dx.doi.org/10.1017/CBO9781139923279">10.1017/CBO9781139923279</a>&gt;</p>
</div>

But this would be better:

<p><span class="citation">([n.d.])</span></p>
<div class="references">
<p>[n.d.]. &lt;<a href="http://dx.doi.org/10.1017/CBO9781139923279">http://dx.doi.org/10.1017/CBO9781139923279</a>&gt;</p>
</div>

I asked about this at citation-style-language/styles#1428, where it was thought that citeproc variants should detect where the prefix is a URL rather than changing the method for writing this in CSL.

@adunning
Copy link
Contributor Author

adunning commented Mar 3, 2015

Also, it might be worth pointing out that the DOI Foundation states that http://doi.org/ is now the preferred resolver.

jgm added a commit that referenced this issue Mar 8, 2015
@jgm jgm closed this as completed in d952693 May 3, 2015
@adunning
Copy link
Contributor Author

adunning commented May 4, 2015

Thank you!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant