我正在使用
\newcommand{\mycite}[2]{\citeauthor{kazem2003design}'s \citeyear{kazem2003design}}
但是,作者的交叉引用不起作用。年份的交叉引用起作用。
在这里According to Kazem et al.’s studies (2003), blablabla
Kazem et al cross-referencing
不管用。(2003)
交叉引用正在工作(它变为蓝色文本)
代码:
\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[style=authoryear, backend=biber]{biblatex}
\DeclareNameAlias{sortname}{family-given}
\addbibresource{biblatex-examples.bib}
\begin{document}
According to \citeauthor{kazem2003design}'s studies \autocite*{kazem2003design}, blablabla
\printbibliography
\end{document}
参考:
@inproceedings{kazem2003design,
title={Design considerations for a background auditory display to aid pilot situation awareness},
author={Kazem, Mandana LN and Noyes, Janet M and Lieven, Nicholas J},
year={2003},
organization={Georgia Institute of Technology}
}
答案1
嗯,你给出的代码中有一些错误,我在下面的 MWE 中进行了纠正。
要解决您的问题,请添加代码
\DeclareCiteCommand{\citeauthor}
{\boolfalse{citetracker}%
\boolfalse{pagetracker}%
\usebibmacro{prenote}}
{\ifciteindex
{\indexnames{labelname}}
{}%
\printtext[bibhyperref]{\printnames{labelname}}}
{\multicitedelim}
{\usebibmacro{postnote}}
你的序言。
使用以下完整的 MWE
\RequirePackage{filecontents}
\begin{filecontents}{\jobname.bib}
@inproceedings{kazem2003design,
title={Design considerations for a background auditory display to aid pilot situation awareness},
author={Kazem, Mandana LN and Noyes, Janet M and Lieven, Nicholas J},
year={2003},
organization={Georgia Institute of Technology}
}
\end{filecontents}
\documentclass[british]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[%
style=authoryear,
backend=biber,
giveninits % <========================================================
]{biblatex}
\addbibresource{\jobname.bib} % \jobname to use the bib file created with filecontents
\DeclareNameAlias{sortname}{family-given}
\usepackage[unicode,colorlinks,citecolor=blue]{hyperref} % <============
\newcommand{\mycite}[1]{\citeauthor{#1}'s \citeyear{#1}} % <============
\DeclareCiteCommand{\citeauthor} % <====================================
{\boolfalse{citetracker}%
\boolfalse{pagetracker}%
\usebibmacro{prenote}}
{\ifciteindex
{\indexnames{labelname}}
{}%
\printtext[bibhyperref]{\printnames{labelname}}}
{\multicitedelim}
{\usebibmacro{postnote}}
\begin{document}
According to \citeauthor{kazem2003design}'s studies \autocite*{kazem2003design}, blablabla
\mycite{kazem2003design} % <============================================
\printbibliography
\end{document}
您将获得以下结果:
请注意,\citeyear
我添加的更正命令中没有链接\mycite
!