[Tex/LaTex] How to get the author and chapter names in header; alternatively using fancyhdr

book-designfancyhdrheader-footer

I want to set a header/footer which shows:

  1. Chapter name on odd numbered page;
  2. Author name (different authors in different chapters) in even numbered pages;
  3. Page number in central footer.

Any help would be appreciated.
Thanks.

Updated:
A MWE is given as

\documentclass{book}  
\usepackage{blindtext}  
\usepackage{fancyhdr}  
\pagestyle{fancy}  
\begin{document}

\chapter{Wombat}  
Author Aa, And Author Bb  
\blindtext[5]  
\section{tabmow}  
\blindtext[5]  

\chapter{Capybara}  
Author Cc, And Author Dd  
\blindtext[5]  
\section{arabypac}  
\blindtext[5]  

\end{document}

Best Answer

The following introduces \chapterauthor to set and store the authors associated with your \chapters. This allows you to use the stored details within the \fancyhead[LE] part.

enter image description here

\documentclass{book}

\usepackage{blindtext}
\usepackage{fancyhdr}

\makeatletter
\newcommand{\chapterauthor}[1]{%
  \def\@chapterauthor{#1}% Store chapter authors
  {\bfseries #1}% Set chapter authors
  \par
}

\fancyhf{}% Clear header/footer
\fancyhead[RO]{\leftmark}% Chapter details in book
\fancyhead[LE]{\@chapterauthor}% Stored \chapterauthor details
\fancyfoot[C]{\thepage}
%\renewcommand{\headrulewidth}{0pt}% Remove header rule
%\renewcommand{\footrulewidth}{0pt}% Remove footer rule (default)
\pagestyle{fancy}
\makeatother

\begin{document}

\chapter{Wombat}
\chapterauthor{Author Aa, And Author Bb}
\blindtext[5]
\section{tabmow}
\blindtext[5]

\chapter{Capybara}
\chapterauthor{Author Cc, And Author Dd}
\blindtext[5]
\section{arabypac}
\blindtext[5]

\chapter*{Mara}
\chapterauthor{}% No chapter author
\blindtext[5]
\section{aram}
\blindtext[5]

\end{document}