Page LayoutRe: fancyhdr | Settings not working as expected

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
doonyakka
Posts: 9
Joined: Fri May 28, 2010 2:50 pm

fancyhdr | Settings not working as expected

Post by doonyakka »

Hi,

I've recently been having problems getting fancyhdr to do what it's supposed to, namely to alternate headings according to the values of LRC with OE.

The following minimal example results in "Header 1" appearing in \rhead on every page, and both \thepage and "Author" appearing adjacent two each other in \lfoot on every page.

Code: Select all

\documentclass{article}
\usepackage{fancyhdr}
\usepackage{blindtext}

\pagestyle{fancy}
\fancyhf{}
\fancyhead[RO,LE]{\bfseries Header 1}
\fancyfoot[LE,RO]{\thepage}
\fancyfoot[LO,CE]{Author}
\fancyfoot[CO,RE]{\date}

\begin{document}

\Blinddocument

\end{document}
Presumably, this isn't as it should be. Am I doing something wrong?

Any help much appreciated.

Best,
doonyakka
Last edited by doonyakka on Mon Dec 05, 2011 2:05 pm, edited 2 times in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

Learn LaTeX easily with newest books:

The LaTeX Beginner's Guide: 2nd edition and perfect for students writing a thesis

The LaTeX Cookbook: 2nd edition full of practical examples for mathematics, physics, chemistry, and more

LaTeX Graphics with TikZ: the first book about TikZ for perfect drawings in your LaTeX thesis

User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Re: fancyhdr | Settings not working as expected

Post by localghost »

These settings only make sense in a two-sided document. For details see the fancyhdr manual.


Thorsten
doonyakka
Posts: 9
Joined: Fri May 28, 2010 2:50 pm

Re: fancyhdr | Settings not working as expected

Post by doonyakka »

Thanks Thorsten :)

Solution: Add [twoside] to \documentclass options.
Post Reply