使用 babelbib 显示上次访问/urldate 字段

使用 babelbib 显示上次访问/urldate 字段

显然默认babelbib显示last accessed/urldate字段,但对我来说似乎不起作用。我尝试更改 bibliographystyle,但也没有解决问题。此外,我不能直接将其更改为biblatex,因为我使用的文档类显然有太多依赖项。

我希望参考书目看起来像:

Wikipedia: Stackoverflow. http://en.wikipedia.org/wiki/Stack_Overflow, last accesed: 2014-02-17

以下是 MWE:

\begin{filecontents*}{mwe.bib}
@misc{wiki:SO,
    Date-Added = {2014-02-25 20:50:43 +0000},
    Date-Modified = {2014-02-26 09:05:39 +0000},
    Howpublished = {\url{http://en.wikipedia.org/wiki/Stack_Overflow}},
    Language = {english},
    Title = {Wikipedia: StackOverflow},
    Urldate = {2014-02-17},
    Bdsk-Url-1 = {http://en.wikipedia.org/wiki/Stack_Overflow}}
\end{filecontents*}

\documentclass[a4paper,11pt,titlepage]{scrbook}

\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}

\usepackage{url}
\usepackage{hyperref}
\usepackage[english,ngerman]{babel}
\usepackage[fixlanguage]{babelbib}
\selectbiblanguage{english}

\begin{document}

This page is about StackOverflow\cite{wiki:SO}.

{\bibliographystyle{plain}}
{\bibliographystyle{babalpha-fl}}

\bibliography{mwe}

\end{document}

答案1

文档中没有对此进行解释,但为了urldate使用该字段,bib 条目必须包含一个url字段。因此,您需要做的就是将您的 url 从该字段移到该字段howpublished中。url

示例输出

\begin{filecontents*}{mwe.bib}
@misc{wiki:SO,
    Date-Added = {2014-02-25 20:50:43 +0000},
    Date-Modified = {2014-02-26 09:05:39 +0000},
    url = {http://en.wikipedia.org/wiki/Stack_Overflow},
    Language = {english},
    Title = {Wikipedia: StackOverflow},
    Urldate = {2014-02-17},
    Bdsk-Url-1 = {http://en.wikipedia.org/wiki/Stack_Overflow}}
\end{filecontents*}

\documentclass[a4paper,11pt,titlepage]{scrbook}

\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}

\usepackage{url}
\usepackage{hyperref}
\usepackage[english,ngerman]{babel}
\usepackage[fixlanguage]{babelbib}
\selectbiblanguage{english}

\begin{document}

This page is about StackOverflow\cite{wiki:SO}.

\bibliographystyle{babalpha-fl}

\bibliography{mwe}

\end{document}

顺便说一句,您的代码包含两个\bibliographystyle命令,这意味着第二个命令(您需要的命令!)将被忽略。我已删除对样式的调用plain

相关内容