0

I want to suppress the string for pages ("pp.", or "S." in German) only in the bibliography, not in citations in the text. When I add DefineBibliographyStrings to the preamble, the job is done for both, bibliography and citations in text. When I move the command to a position right before \printbibliography, I receive the error message "Can only be used in preamble". Any suggestions how to make that working?

MNWE:

\documentclass[ngerman]{book}
\usepackage[style=authortitle-dw,sorting=nyt,backend=biber,bibencoding=latin1]{biblatex}
\addbibresource{<database>.<extension>}
\begin{document}

\cite{<some-ref>}

\DefineBibliographyStrings{ngerman}{pages={}} 
\printbibliography
\end{document}

1 Answer 1

1

The formatting of pages in the bibliography (more precisely of the pages field in the bibliography) is controlled by the field format pages. Its default definition is

\DeclareFieldFormat{pages}{\mkpageprefix[bookpagination]{#1}}

but you can easily redefine it to drop the page prefix:

\DeclareFieldFormat{pages}{#1}

This does not affect the page numbers in citation, since those are controlled by the postnote field format.

It is (almost?) never a good idea to try and suppress bibstrings by simply redefining them to be empty.

\documentclass[ngerman]{article}
\usepackage[T1]{fontenc}
\usepackage{babel}
\usepackage{csquotes}
\usepackage[style=authortitle-dw,sorting=nyt,backend=biber]{biblatex}

\DeclareFieldFormat{pages}{#1}

\addbibresource{biblatex-examples.bib}
\begin{document}
\cite[380]{sigfridsson}

\printbibliography
\end{document}

Sigfridsson, Emma und Ulf Ryde: Comparison of methods for deriving atomic charges from the electrostatic potential and moments, in: Journal of Computational Chemistry 19.4 (1998), 377–395.

1
  • Perfect. That was the answer I was looking for. Thank you very much!!! Feb 18, 2020 at 23:40

You must log in to answer this question.

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