I've searched and read the answers for this problem all over the web. However, it seems something else is wrong with my document. I'm using the book document class in latex. I have not used any \pagestyle{empty} or anything else anywhere. But why page numbering only appears on the first page of each chapter, instead of every page of the document? Please tell me how can I get it on all pages.
Here is my preamble:
\documentclass[a4paper,12pt,openany]{book}
\usepackage[utf8]{inputenc}
\usepackage{amsthm,amssymb,amsmath}
\usepackage{bbm}
\usepackage[top=40mm, bottom=40mm, left=25mm, right=25mm]{geometry}
\usepackage{graphicx}
\usepackage{framed}
\usepackage[pagebackref=false,colorlinks,linkcolor=blue,citecolor=blue]{hyperref}
\usepackage{fancyhdr}
\newcommand{\changefont}{\fontsize{7}{11}\selectfont}
\fancyhf{}
\fancyhead[LE,RO]{\changefont \slshape \rightmark} %section
\fancyhead[RE,LO]{\changefont \slshape \leftmark} %chapter
\pagestyle{fancy}
\usepackage{setspace}
\onehalfspacing
\usepackage{tocloft}
\usepackage{multirow}
\usepackage{subcaption}
\usepackage{caption}
\usepackage{booktabs}
\usepackage{diagbox}
\usepackage[dvipsnames]{xcolor}
\usepackage[morefloats=100]{morefloats}
\usepackage{biblatex}
\addbibresource{MyReferences.bib}
And here is my document:
\begin{document}
\input{title}
\clearpage
\frontmatter
\addcontentsline{toc}{chapter}{Abstract}
\input{abstract}
\clearpage
\tableofcontents
\clearpage
\addcontentsline{toc}{chapter}{List of Figures}
\listoffigures
\clearpage
\addcontentsline{toc}{chapter}{List of Tables}
\listoftables
\clearpage
\mainmatter
\include{chapter1/Introduction}
\include{chapter2/Definitions}
\include{chapter3/Background}
\include{chapter4/Methods}
\include{chapter5/Experiments}
\include{chapter6/Conclusion}
\printbibliography[heading=bibintoc, title={Bibliography}]
\appendix
\include{appendix1}
\include{appendix2}
\include{appendix3}
\include{appendix4}
\end{document}
Again, I have not used any \pagestyle{...} command in chapters or appendices.