1

How can I make sure that the references page has no number in the header (i. e., I still want a header, but without a number).

enter image description here

MWE with the problem:

\documentclass[]{article}
\usepackage{fancyhdr}
\fancyhf{} % clear the headers
\fancyhead[LE,RO]{%
   % We want italics
   \itshape
   % The chapter number only if it's greater than 0
   \ifnum\value{section}>0  \thesection. \fi
   % The chapter title
   \leftmark}

\fancyfoot[C]{\thepage}

\fancypagestyle{plain}{
  \renewcommand{\headrulewidth}{0pt}
  \fancyhf{}
  \fancyfoot[C]{\thepage}
}

\setlength{\headheight}{14.5pt}
\pagestyle{fancy}
\begin{document}

\section{Example}

\clearpage

\renewcommand{\thepage}{}


\begin{thebibliography}{99}


\end{thebibliography} 


\end{document}
1

Define a new page style, say, bib like

\fancypagestyle{bib}{
  \fancyhf{}
  \fancyhead[LE,RO]{%
   % We want italics
   \itshape
   % The chapter title
   \leftmark}
   \fancyfoot[C]{\thepage}
}

without the section number and then just before \begin{thebibliography}{99} issue \pagestyle{bib}

Code:

\documentclass[]{article}
\usepackage{fancyhdr}
\fancyhf{} % clear the headers
\fancyhead[LE,RO]{%
   % We want italics
   \itshape
   % The chapter number only if it's greater than 0
   \ifnum\value{section}>0  \thesection. \fi
   % The chapter title
   \leftmark}

\fancyfoot[C]{\thepage}

%%% this is not needed as this does nothing. plain page style is exactly this one.
%\fancypagestyle{plain}{
%  \renewcommand{\headrulewidth}{0pt}
%  \fancyhf{}
%  \fancyfoot[C]{\thepage}
%}

\fancypagestyle{bib}{
  \fancyhf{}
  \fancyhead[LE,RO]{%
   % We want italics
   \itshape
   % The chapter title
   \leftmark}
   \fancyfoot[C]{\thepage}
}

\setlength{\headheight}{14.5pt}
\pagestyle{fancy}
\begin{document}

\section{Example}

\clearpage

%\renewcommand{\thepage}{}
\pagestyle{bib}

\begin{thebibliography}{99}


\end{thebibliography}


\end{document}

enter image description here

3
  • Thanks for your help but I don't think you completely understood what I wanted. What I want is that the 1. in the header of the references page disappears (the 1 that is circled in the image in the OP).
    – texfan
    May 14 '15 at 12:40
  • Ah, I see you updated it now, I'll have a look, thanks :)!
    – texfan
    May 14 '15 at 12:40
  • This does what I wanted, thank you for your help :)!
    – texfan
    May 14 '15 at 12:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.