1

How can I remove the number from a single page, but still have the header unchanged? I want to remove the number, and all the ways i have tried, the header is removed as well, or the header is replaced with the page number.

I'm using fancyhdr to define my header and footer in general.

\documentclass{article}
\usepackage{fancyhdr}
\setlength{\headheight}{15.2pt}
\pagestyle{fancy}
\lhead{name}
\chead{}
\rhead{affiliation}
\lfoot{}
\cfoot{}
\rfoot{\thepage}

\begin{document}

\thispagestyle{empty} %removes both header and footer (dont want that)
\newpage

\pagestyle{headings} %footer is gone, but header shows the page number,
and not what i have set the header to be

\end{document}
  • 1
    Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. – user11232 Feb 17 '15 at 14:11
  • 1
    Please add a minimal working example (MWE) – user11232 Feb 17 '15 at 14:11
  • ! Undefined control sequence. l.23 \lipsum – David Carlisle Feb 17 '15 at 14:26
2

You can define a new page style with an empty foot:

\documentclass{article}
\usepackage{fancyhdr,lipsum}
\setlength{\headheight}{15.2pt}
\pagestyle{fancy}
\lhead{name}
\chead{}
\rhead{affiliation}
\lfoot{}
\cfoot{}
\rfoot{\thepage}

\fancypagestyle{zzz}{
\lhead{name}
\chead{}
\rhead{affiliation}
\lfoot{}
\cfoot{}
\rfoot{}
}
\begin{document}

\thispagestyle{zzz} % empty foot
\lipsum
\newpage


and not what i have set the header to be

\end{document}

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.