如何使用 biblatex 在 URL 后添加点?
\RequirePackage{filecontents}
\begin{filecontents}{\jobname.bib}
@Electronic{musk,
author = {Elon Musk},
title = {Tesla Model X},
url = {https://www.tesla.com/modelx?redirect=no},
date = {2017-07-04},
institution = {Tesla},
urldate = {2018-10-16}}
}
\end{filecontents}
\documentclass{article}
\usepackage[style=authortitle,]{biblatex}
\addbibresource{\jobname.bib}
\begin{document}
Let's cite! \footcite{musk}
\printbibliography
\end{document}
答案1
如果你还删除urldate
了Biblatex 更改上次访问看上去并不是那么糟糕。
我们只需要重新定义bibmacrourl+urldate
并\setunit*{\addspace}%
改为\setunit*{\newunitpunct}%
。
\RequirePackage{filecontents}
\begin{filecontents}{\jobname.bib}
@online{musk,
author = {Elon Musk},
title = {Tesla Model X},
url = {https://www.tesla.com/modelx?redirect=no},
date = {2017-07-04},
institution = {Tesla},
urldate = {2018-10-16},
}
\end{filecontents}
\documentclass{article}
\usepackage[style=authortitle,]{biblatex}
\DeclareFieldFormat{urldate}{\bibstring{urlseen}\space#1}
\renewbibmacro*{url+urldate}{%
\usebibmacro{url}%
\iffieldundef{urlyear}
{}
{\setunit*{\newunitpunct}%
\usebibmacro{urldate}}}
\addbibresource{\jobname.bib}
\begin{document}
Let's cite! \footcite{musk}
\printbibliography
\end{document}