Theses, Books, Title pagesMoving page numbers

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
Post Reply
fabriziomiano
Posts: 5
Joined: Thu Jun 08, 2017 6:21 pm

Moving page numbers

Post by fabriziomiano »

Hi,

thank you guys very much indeed once again for this awesome template and the detailed README you've provided.

Let me go straight to my question:
In the first page of every chapter, the page number is at the bottom, whereas in the other pages it is at the top-right corner.
Is there an easy way to leave the number at the bottom?

I couldn't find an easy one in the layout section in classicthesis.sty; I guess I must be missing something.

Thanks for your help

Cheers,
Fab

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org
LaTeX Beginner's Guide LaTeX Cookbook LaTeX TikZ graphics TikZによるLaTeXグラフィックス
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

Moving page numbers

Post by Stefan Kottwitz »

Hi Fab!

Chapter or section name and page number are often in the header, but the header is commonly omitted on pages that start with a chapter heading. That's because the heading with the chapter name would be redundant. In that case also the page number goes to the bottom.

You could have the same style for all pages by changing

\pagestyle{scrheadings}

to

\pagestyle{plain}

in the file main.tex. Or simply delete \pagestyle{scrheadings} since plain is already set above. But then you also don't have chapter or section names in the header.

Keeping the names in the header but page numbers in the footer is also a bit strange when I think about it: both is not a decoration but for finding things. A reader searches in the table of contents, gets a section name and a page number, then looks for it in the book. If you separate section name header and page numbers, the reader has to look both at the top and at the bottom of pages to find something.

That's why I would keep header (with chapter or section name) together with the page number. And none of them at a chapter starting page header. Just the number in the bottom. ;-) That's the original way. Just re-consider, maybe you would like to keep that very established way.

Stefan
LaTeX.org admin
fabriziomiano
Posts: 5
Joined: Thu Jun 08, 2017 6:21 pm

Moving page numbers

Post by fabriziomiano »

Hi Stefan,

thanks a lot for your prompt reply and the nice digression.
Although I tried what you suggested I still prefer to have both the header and the page number at the bottom.

Would you be so kind to tell me how to do it, if there's an easy way to do it?

Thank you very much.

Cheers,
Fab
User avatar
Stefan Kottwitz
Site Admin
Posts: 10290
Joined: Mon Mar 10, 2008 9:44 pm

Moving page numbers

Post by Stefan Kottwitz »

Hi Fab,

you can add this to your preamble in main.tex:

Code: Select all

\rohead{\mbox{\hfil{\headmark}}}
\lehead{\mbox{\headmark\hfil}}
\rofoot{\small\thepage}
\lefoot{\small\thepage}
If it should be centered, replace the last two lines by

\cfoot{\small\thepage}

Stefan
LaTeX.org admin
fabriziomiano
Posts: 5
Joined: Thu Jun 08, 2017 6:21 pm

Moving page numbers

Post by fabriziomiano »

Thank you very much Stefan.
It worked!

Cheers,
Fab
tenicko17
Posts: 2
Joined: Sat Apr 21, 2018 9:38 pm

Moving page numbers

Post by tenicko17 »

Hi,

first of all, thank you guys very much indeed once again for this awesome template you've provided.

my question is:
In the first page of every chapter, the page number is at the top-right corner.
Is there an easy way to put the first page number of the chapter at the bottom of the center?

I couldn't find an easy one;

Thanks for your help

Cheers,
Teo
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Moving page numbers

Post by Johannes_B »

In the preamble of your document, use

Code: Select all

\ohead*{}\cfoot*{\ṕagemark}
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
tenicko17
Posts: 2
Joined: Sat Apr 21, 2018 9:38 pm

Moving page numbers

Post by tenicko17 »

Thanks for the reply.
sorry if I probably did not understand, I'm new to write in latex and maybe my question was badly placed.
Unfortunately it did not work.
I tried to put your code in the main.tex in overleaf at the following site:

https://www.latextemplates.com/template ... ral-thesis

at line 256 after the following code:

Code: Select all

\pagestyle{thesis} % Return the page headers back to the "thesis" style
I unfortunately give me the following error:

./Chapters/Chapter1.tex:42: Undefined control sequence. \sls@ps@plain.thesis@odd@middle@foot ->\� ��agemark l.42 \subsection {A Short Math Guide for \LaTeX{}}

However, I do not think I have explained myself well about the result I would like to achieve. If you see the latex on the site mentioned above, the page number "1" remains in the above right corner.
I would like to obtain that this number "1" is at the bottom and in the center of the pages.
For the remaining pages of the chapter, however, I would like the style to remain unchanged and quini remain above.
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

Moving page numbers

Post by Johannes_B »

\ohead{\pagemark}\cfoot[\pagemark]{}

Should do what you want.

Concerning the error message, a minimal working example would be needed. Are you able to come up with one? Maybe the overleaf support team can help you faster by sending them the ID of your project.

Please have a look at the quick guide as well.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Post Reply