I am writing the thesis. I want to add page number in right side of page header and in left side of header i want to write the chapter name. I use the following commands but it does not work.
\documentclass[letterpaper,12pt,titlepage,oneside,final]{article}
\usepackage{fancyhdr}
\fancyhead{} % Clears all page headers and footers
\pagestyle{fancy}
\lhead{}
\rhead{\thepage}
\cfoot{center of the footer!}
\renewcommand{\headrulewidth}{0.4pt}
\renewcommand{\footrulewidth}{0.4pt}
\begin{document}
\lhead{\emph{chapter1}}
\input{chapter1/introduction}
\lhead{\emph{chapter1}}
\input{chapter2/name}
\lhead{\emph{chapter3}}
\input{chapter3/name2}
\lhead{\emph{chapter3}}
\input{chapter4/name3}
\end{document}
Best Answer
If i understand the question correctly, the following is what you are looking for.