在乳胶中,我想知道如何创建一个命令以引用期刊的名称。它不必过度引用。对于前。如果我有以下文件
\documentclass{article}
\usepackage{filecontents}
% Sample bibliography
\begin{filecontents}{\jobname.bib}
@article{AUTH2024,
author = {Author, A. and Author, B. and Author, C.},
title = {Title of the Article},
journal = {Journal Name},
year = {2024},
volume = {1},
pages = {1-10},
}
\end{filecontents}
\begin{document}
\citejournal{AUTH2024}
\bibliographystyle{plain}
\bibliography{\jobname}
\end{document}
在上述文档中,仅应打印期刊名称,该名称来自 citekey 的 bibtex 中的
journal
元素。
谢谢你。
如果您从 bibtex 切换到 biblatex,这非常容易:
\documentclass{article}
\usepackage{biblatex}
\begin{filecontents}{\jobname.bib}
@article{AUTH2024,
author = {Author, A. and Author, B. and Author, C.},
title = {Title of the Article},
journal = {Journal Name},
year = {2024},
volume = {1},
pages = {1-10},
}
\end{filecontents}
\addbibresource{\jobname.bib}
\DeclareCiteCommand{\citejournal}{}{\printfield{journaltitle}}{}{}
\begin{document}
\cite{AUTH2024}
\citejournal{AUTH2024}
\printbibliography
\end{document}