# Beamer citation in footnote

What I want: A bibliography printing style in Beamer, which combines \footpartcite with \autocite. The first instance of citation of an item will be like this:

All the subsequent instances will not have any description in footnote (but it will link to the first instance):

What I have: With my MWE (see below) I am able to get this for the first instance (notice the footnotemarks):

Any help is welcome.

Update: I also have some \footnotes which I want unchanged (see the following image).

\documentclass{beamer}
\usepackage[style=numeric]{biblatex}

\usepackage{filecontents}
\begin{filecontents*}{myreferences.bib}
@online{bad,
author = {Bad Man},
year = {1313},
title = {Bad Title},
url = {http://badurl.com/},
}
\end{filecontents*}
\addbibresource{myreferences.bib}

%https://tex.stackexchange.com/a/165016/38244
\hypersetup{
colorlinks,
citecolor=red,
linkcolor=blue,
%   backref=true
}

% https://tex.stackexchange.com/a/29931/38244
\DeclareCiteCommand{\footpartcite}[\mkbibfootnote]
{\usebibmacro{prenote}}%
{\usebibmacro{citeindex}%
\mkbibbrackets{\usebibmacro{cite}}%
\setunit{\addnbspace}
\printnames{labelname}%
\setunit{\labelnamepunct}
\printfield[citetitle]{title}%
\newunit
\printfield[]{year}}
{\addsemicolon\space}
{\usebibmacro{postnote}}

%%%\DeclareMultiCiteCommand{\footpartcites}[\mkbibfootnote]{\footpartcite}{\addsemicolon\space}

\begin{document}

\begin{frame}{What I found}
Something\footnote{This is a footnote with index 1}

First time, \autocite{bad} \footpartcite{bad}

Another thing\footnote{This footnote index should be 2}
\end{frame}

\begin{frame}{Again}
Next time, \autocite{bad} only
\end{frame}

\end{document}


UPDATE (2) One elegant (yet partial) solution is given by samcarter (see below). The only thing left is to link the citations to the first footnote.

## 2 Answers

As a quick hack, simply change the definition of the footnotemarks to be empty.

\documentclass{beamer}
\usepackage[style=numeric]{biblatex}

\usepackage{filecontents}
\begin{filecontents*}{myreferences.bib}
@online{bad,
author = {{Bad Man}},
year = {1313},
title = {Bad Title},
url = {http://badurl.com/},
}
\end{filecontents*}
\addbibresource{myreferences.bib}

%https://tex.stackexchange.com/a/165016/38244
\hypersetup{
colorlinks,
citecolor=red,
linkcolor=blue,
%   backref=true
}

% https://tex.stackexchange.com/a/29931/38244
\DeclareCiteCommand{\footpartcite}[\mkbibfootnote]
{\usebibmacro{prenote}}%
{\usebibmacro{citeindex}%
\mkbibbrackets{\usebibmacro{cite}}%
\setunit{\addnbspace}
\printnames{labelname}%
\setunit{\labelnamepunct}
\printfield[citetitle]{title}%
\newunit
\printfield[]{year}}
{\addsemicolon\space}
{\usebibmacro{postnote}}

%%%\DeclareMultiCiteCommand{\footpartcites}[\mkbibfootnote]{\footpartcite}{\addsemicolon\space}

\setbeamertemplate{footnote}{\insertfootnotetext}

\makeatletter
\def\@makefnmark{}
\makeatother

\begin{document}

\begin{frame}{What I found}
First time, \autocite{bad} \footpartcite{bad}
\end{frame}

\begin{frame}{Again}
Next time, \autocite{bad} only
\end{frame}

\end{document}


And in combination with footnotes (with a little help from https://tex.stackexchange.com/a/170512/36296):

\documentclass{beamer}
\usepackage[style=numeric,citecounter=true,citetracker=true]{biblatex}
\usepackage{filecontents}
\begin{filecontents*}{myreferences.bib}
@online{bad,
author = {{Bad Man}},
year = {1313},
title = {Bad Title},
url = {http://badurl.com/},
}
\end{filecontents*}
\addbibresource{myreferences.bib}

%https://tex.stackexchange.com/a/165016/38244
\hypersetup{
colorlinks,
citecolor=red,
linkcolor=blue,
%   backref=true
}

\let\svthefootnote\thefootnote

% https://tex.stackexchange.com/a/29931/38244
\DeclareCiteCommand{\cite}
{\usebibmacro{prenote}}%
{%
\ifciteseen{}{%
\usebibmacro{citeindex}%
\let\thefootnote\relax%
\footnotetext{%
\mkbibbrackets{\usebibmacro{cite}}%
\setunit{\addnbspace}
\printnames{labelname}%
\setunit{\labelnamepunct}
\printfield[citetitle]{title}%
\newunit%
\printfield[]{year}%
}%
\let\thefootnote\svthefootnote%
}%
\autocite{\thefield{entrykey}}%
}
{\addsemicolon\space}
{\usebibmacro{postnote}}

\begin{document}

\begin{frame}{What I found}
test\footnote{test}

First time, \cite{bad}

test\footnote{test}
\end{frame}

\begin{frame}{Again}
Next time, \cite{bad} only
\end{frame}

\end{document}


• Thanks, but I also have \footnotes. :-( – hola Aug 16 '17 at 17:03
• @pushpen.paul Please see my second solution. – samcarter_is_at_topanswers.xyz Aug 16 '17 at 18:24
• It works... only a minor issue remains. The all instances are linked to the first page of the document (I wanted it to link to the first instance) :-) – hola Aug 16 '17 at 19:26
• Apart from that, is it possible to use only one command that will check the number of instances and do the rest automatically? – hola Aug 16 '17 at 19:31
• @pushpen.paul no idea about the links, but to make this automatic, you can have a look at the \ifciteseen test of biblatex, see tex.stackexchange.com/a/358011/36296 for an example. – samcarter_is_at_topanswers.xyz Aug 16 '17 at 19:35

All that seems to be missing is a \blx@anchor in the footnotetext. In order to be able to use that \makeatletter and \makeatother are required. And I have added another test slide in the beginning to show that it does not link to the first slide anymore. Apart from that it's exactly samcarter's answer.

\documentclass{beamer}
\usepackage[style=numeric,citecounter=true,citetracker=true]{biblatex}
\usepackage{filecontents}
\begin{filecontents*}{myreferences.bib}
@online{bad,
author = {{Bad Man}},
year = {1313},
title = {Bad Title},
url = {http://badurl.com/},
}
\end{filecontents*}
\addbibresource{myreferences.bib}

%https://tex.stackexchange.com/a/165016/38244
\hypersetup{
colorlinks,
citecolor=red,
linkcolor=blue,
%   backref=true
}

\let\svthefootnote\thefootnote

\makeatletter
% https://tex.stackexchange.com/a/29931/38244
\DeclareCiteCommand{\cite}
{\usebibmacro{prenote}}%
{%
\ifciteseen{}{%
\usebibmacro{citeindex}%
\let\thefootnote\relax%
\footnotetext{%
\blx@anchor
\mkbibbrackets{\usebibmacro{cite}}%
\setunit{\addnbspace}
\printnames{labelname}%
\setunit{\labelnamepunct}
\printfield[citetitle]{title}%
\newunit%
\printfield[]{year}%
}%
\let\thefootnote\svthefootnote%
}%
\autocite{\thefield{entrykey}}%
}
{\addsemicolon\space}
{\usebibmacro{postnote}}
\makeatother

\begin{document}

\begin{frame}{Test}
content
\end{frame}

\begin{frame}{What I found}
test\footnote{test}

First time, \cite{bad}

test\footnote{test}
\end{frame}

\begin{frame}{Again}
Next time, \cite{bad} only
\end{frame}

\end{document}

• Umm... Having a slight problem when I'm citing inside a table. The same cite key is printed in the footnote, although it is printed once already... Should I open a new (follow-up) question? – hola May 30 '19 at 19:26
• @pushpen.paul yes, opening a follow-up question and posting it's link here in the comments would be good. Using the example from my answer and putting the citation inside a tabular inside of a table I can not recreate your problem. – jakun May 31 '19 at 8:17
• Yes, I just figured out the problem is not with tabular, but with a previous algorithm. – hola May 31 '19 at 9:57