我尝试按照现代 APA 7 标准引用维基百科。根据普渡大学猫头鹰维基百科是一个特例,默认情况下biblatex-apa
会像这样引用维基百科:
注册转移语言。(2021 年)。维基百科。
当它应该是这样的:
注册转移语言。(2021 年 2 月 1 日)。维基百科。https://en.wikipedia.org/w/index.php?title=Register_transfer_language&oldid=1003495175
仅通过查看引用无法清楚了解的一个细节是,日期应该是访问日期,而不是发布日期。
我的围兜条目如下所示:
@inreference{wiki:rtl,
title = "{Register Transfer Language}",
publisher = "Wikipedia",
year = "2021",
howpublished = {\url{http://en.wikipedia.org/w/index.php?title=Register\%20transfer\%20language&oldid=1003495175}},
}
我的简单 Latex 模板如下所示:
\documentclass[12pt]{article}
%Packages
\usepackage{fontspec}
\usepackage[utf8]{inputenc}
\usepackage[left=1in, right=1in, bottom=1in, top=1in]{geometry}
\usepackage{titlesec}
\usepackage{titling}
\usepackage{setspace}
\usepackage{fancyhdr}
\usepackage[colorlinks=true, allcolors=blue]{hyperref}
\usepackage[super]{nth}
\fancyfoot{}
\rhead{Lastname, \thepage}
\pagestyle{fancy}
\usepackage{xurl} % Better URL management than regular URL.
\usepackage[style=apa,backend=biber]{biblatex} % Biber
\usepackage{amsmath}
\usepackage{graphicx}
\usepackage[colorinlistoftodos]{todonotes}
\usepackage[colorlinks=true, allcolors=blue]{hyperref}
\usepackage{listings}
\usepackage{color} %red, green, blue, yellow, cyan, magenta, black, white
\definecolor{mygreen}{RGB}{28,172,0} % color values Red, Green, Blue
\definecolor{mylilas}{RGB}{170,55,241}
% Sans-Serif Font
\newfontface{\headingfont}{Linux Biolinum O}
\titleformat*{\section}{\Large\headingfont}
\titleformat*{\subsection}{\Large\headingfont}
\titleformat*{\subsubsection}{\large\headingfont}
\addbibresource{refer.bib}
% Master references file.
% Serif Font
\setmainfont{Times New Roman}
% For programming languages.
\lstset{language=C++,%
basicstyle=\color{red},
breaklines=true,%
keywordstyle=\color{blue},%
morekeywords=[2]{1}, keywordstyle=[2]{\color{black}},
identifierstyle=\color{black},%
stringstyle=\color{mylilas},
commentstyle=\color{mygreen},%
showstringspaces=false,%without this there will be a symbol in the places where there is a space
numbers=left,%
numberstyle={\color{black}},% size of the numbers
numbersep=9pt, % this defines how far the numbers are from the text
emph=[1]{for,end,break},emphstyle=[1]\color{red}, %some words to emphasise
tabsize=4,
% title=\lstname
}
\renewcommand{\headrulewidth}{0pt}
\newcommand{\teacher}[2]{
\def\theteacher{#1: #2}
}
\newcommand{\myclass}[1]{
\def\theclass{#1}
}
%Title Info
\author{<++>}
\date{\today}
\teacher{<++>}{<++>}
\title{<++>}
\myclass{<++>}
%Renewing commands continued
\renewcommand{\maketitle}{
\begin{flushleft}
\theauthor\\
\thedate\\
\theteacher\\
\theclass\\
\end{flushleft}
\begin{center}
\bfseries{\thetitle}
\end{center}
}
%Document
\begin{document}
\doublespace
\maketitle
<++>
\end{document}
我的 LaTeX 引擎是 LuaLaTex,我正在使用 Biber。
答案1
biblatex-apa
有一个广泛的示例.bib
文件,其中包含许多来自 APA 手册的示例。有关维基百科文章,请查看条目10.3:49
( ll. 1299-1305 in biblatex-apa-test-references.bib
)
% (APA 10.3 Example 49)
@INBOOK{10.3:49,
TITLE = {List of Oldest Companies},
BOOKTITLE = {Wikipedia},
URL = {https://en.wikipedia.org/w/index.php?title=List_of_oldest_companies&oldid=878158136},
DATE = {2019-01-13}
}
我在这里只想改变一件事:像你一样,我更喜欢类型@inreference
而不是@inbook
。
\documentclass[american]{article}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[backend=biber, style=apa]{biblatex}
\begin{filecontents}{\jobname.bib}
@inreference{wiki:rtl,
title = {Register Transfer Language},
booktitle = {Wikipedia},
date = {2021-01-29},
url = {http://en.wikipedia.org/w/index.php?title=Register%20transfer%20language&oldid=1003495175},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\addbibresource{biblatex-examples.bib}
\begin{document}
Lorem \autocite{sigfridsson,wiki:rtl}
\printbibliography
\end{document}