4

I'm having an issue that seems like a bug.

When doing a citation inside a footnote with BibLatex using \footnote{\cite[myPrenote][myPostnote]{ref}} and in MLA style, the prenote doesn't show properly. If I include a prenote, it prints "prenote" as the prenote instead of the given input.

Also, if the prenote is left blank, it prints "See " as a prenote, which I can't manage to remove, and is problematic for example when writing in a language other than English, as it does not get translated (with babel, french).

EDIT: I've searched through \biblatex-mla\mla.cbx for prenote, and the \cite{} command is defined on line 722 and 749, but I don't see the problem. Deleting lines 723 to 725 seems to fix it though.

Here's line 722 and following:

\DeclareCiteCommand{\cite}% 1.9 added support for smart switching when used in footnote
  {\iffootnote{\iffieldundef{prenote}
    {\global\undef\cbx@lastprenote
    \printtext{See\addspace}}}
    \usebibmacro{prenote}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}

Here's a MWE of the first issue.

\documentclass{article}
\usepackage[style=mla,backend=biber]{biblatex}
\begin{filecontents}{sample.bib}
    @article{Art1,
        author = "Mike Wazowsky",
        title = "How to scare",
        date = "2020-12-03"
    }
\end{filecontents}
\addbibresource{sample.bib}

\begin{document}
Some text with a footnote\footnote{There should not be "prenote" here: \cite[Look at][p. 12]{Art1}}.
\end{document}

Here's the footnote obtained: 1There should not be "prenote" here: prenoteWazowsky p. 12

3
  • Some text with a footnote\footcite[Look at][p. 12]{Art1} typesets the prenote and postnote in a footnote, and adds the final . too. Is that what you mean?
    – Cicada
    Dec 3, 2020 at 11:30
  • MLA style supports multicites, too: Some text with a footnote\footcites[There is a lot of discussion about this: Look at][p. 12 for example]{Art1}[and also][p 14]{Art1}. It puts the multicite separator ; in automatically.
    – Cicada
    Dec 3, 2020 at 11:39
  • @Cicada \footcite[There should not be "prenote" here: Look at][p. 12]{Art1} with nofullfootnote as a package option does the work, but there's no reason for \cite inside footnote not to work only when using mla (without mla style, it behaves normally). But yeah thanks, I ended up just modifying mla.cbx file (I saved a copy) so it works now, but I'd be curious if someone can figure why it's not working in the first place.
    – Alex867
    Dec 3, 2020 at 14:48

1 Answer 1

2

This indeed looks like a bug. Please always report bugs to the developers of the package via the channels mentioned in the package documentation. (In particular, TeX.SX is not a place to report bugs.)

The public bugtracker of biblatex-mla is at https://github.com/jmclawson/biblatex-mla/issues, but it appears that the project is dormant. There haven't been any updates since late 2016 and several newer bug reports haven't been responded to.

At the moment I'd think twice about using biblatex-mla as it appears to be no longer actively developed and there are some known issues with it (see the list of open issues at https://github.com/jmclawson/biblatex-mla/issues).

In this case the problem is indeed

\DeclareCiteCommand{\cite}% 1.9 added support for smart switching when used in footnote
  {\iffootnote{\iffieldundef{prenote}
    {\global\undef\cbx@lastprenote
    \printtext{See\addspace}}}
    \usebibmacro{prenote}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}

If we slightly change the indentation of the prenote code, we can see the problem

\DeclareCiteCommand{\cite}% 1.9 added support for smart switching when used in footnote
  {\iffootnote{%
     \iffieldundef{prenote}
       {\global\undef\cbx@lastprenote
        \printtext{See\addspace}}}
       \usebibmacro{prenote}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}

The <false> branch of the \iffootnote conditional is missing the curly braces. This means that if \iffootnote is true, only \usebibmacro is gobbled and the {prenote} is left in the input stream and finally printed. Furthermore, the \iffieldundef conditional is missing its complete <false> branch.

The syntactically correct version would be

\DeclareCiteCommand{\cite}% 1.9 added support for smart switching when used in footnote
  {\iffootnote
     {\iffieldundef{prenote}
        {\global\undef\cbx@lastprenote
         \printtext{See\addspace}}
        {\usebibmacro{prenote}}}
     {}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}

Several other \cite macros have the same issue. Since the same code is repeated in all the commands, I suggest you use a bibmacro to keep the number of repetitions down.

\documentclass{article}
\usepackage[style=mla,backend=biber]{biblatex}

\makeatletter
\newbibmacro{mla:prenote:see}{%
  \iffootnote
    {\iffieldundef{prenote}
       {\global\undef\cbx@lastprenote
        \printtext{See\addspace}}
       {\usebibmacro{prenote}}}
    {}}

\DeclareCiteCommand{\cite}% 1.9 added support for smart switching when used in footnote
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}
  
\DeclareCiteCommand{\textcite}
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla}}%
  {}%
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\headlesscite}% 1.9 added alias to starred command for Chicago compatibility
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla:starred:title}}
  {}%
  {\usebibmacro{postnote}}

\DeclareCiteCommand*{\cite}% 1.9 added support for smart switching when used in footnote
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla:starred:title}}
  {}%
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\fullcite}%
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla:title}}
  {}%
  {\usebibmacro{postnote}}

\DeclareCiteCommand{\headlessfullcite}
  {\usebibmacro{mla:prenote:see}}%
  {\usebibmacro{citeindex}%
   \usebibmacro{cite:mla:starred:title}}
  {}%
  {\usebibmacro{postnote}}
\makeatother


\addbibresource{biblatex-examples.bib}

\begin{document}
Some text with a footnote\footnote{There should not be "prenote" here: \cite[Look at][12]{sigfridsson}}.
\end{document}

There should not be ”prenote” here: Look at Sigfridsson and Ryde 12

Now if you don't want to see the automatic "see" at all, you can remove it, from the bibmacro.

\newbibmacro{mla:prenote:see}{%
  \usebibmacro{prenote}}

If you want the see, but want it localised, use

\newbibmacro{mla:prenote:see}{%
  \iffootnote
    {\iffieldundef{prenote}
       {\global\undef\cbx@lastprenote
        \bibstring{see}}
       {\usebibmacro{prenote}}}
    {}}

If you want to see the "p." prefix for postnotes, it is better not to include the "p. " in the postnote, but to tell your style to include the "p." automatically. With biblatex-mla, the following two lines should help

\DeclareFieldAlias{ibidpostnote}{postnote}%
\DeclareFieldAlias{footpostnote}{postnote}%
2
  • Woaw, thank you so much for that very complete answer! I tried using mla-new, but I was having other bigger bugs, like the title of a reference showing-up twice in its bibliography quote. I guess following your suggestion, I might report that too....
    – Alex867
    Dec 5, 2020 at 18:58
  • Thank you, @moewe, for catching this error in the conditionals and offering a clean solution! I'm currently cleaning up bugs in preparation for the 2021 edition of the MLA Handbook. (The last edition came out in 2016.) This fix and will make it into the release, with some other improvements.
    – jmclawson
    May 12, 2021 at 21:35

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .