Centered text in footer

Thank you for your post.

Me too, I tried something similar, but without any success. I am trying to enter small centered text in the footer of my invoice template.

So I took your code, for to proove that I’m not ill.

Result: the entire text is aligned left. All css formatting is ignored or overridden somewhere.
:frowning_face:

1 Like

It’s purely css that is causing your problem.
After changing your css, did you recompile it?

Have you tried <center>My centered text</center>

All kinds of things are possible

1 Like

Hey there @Andreas :wave:,

Can you show us which code you have in which file?

Also keep in mind, you need to add the HTML code in the WebGUI under System-Settings ⇒ Invoices ⇒ PDF Footer.

As mentioned in my post, my CSS modification are in a special file which overrides the standard values of the file. Make sure you added your CSS code in the right file, assets/core/css/custom-pdf.css and you called the correct classes and ids from the additioned HTML code in the settings from before.

I would show you my code snippets, but they changed because I added a picture to my footer instead of real text. This may change on my side, but it is what I have at the moment. Nonetheless, I’m here to help you, at least trying to. :blush:

As said, show us the path and code you added then we can look further.
Also try out what @UnderDog recommended doing.

Sorry, but I was too quick to make a request. I found my mistake.
I placed in assets/core/css/custom-pdf.css the following:

/* PDF footer design */                                                              
.footer-text {
  color: #000000;
  font-size: 80%;  
}                                          
.center {
  text-align: center;
  float: center;
  width: 90%;
}

Now it’s working fine.

2 Likes

Very nice, I’m happy to hear this! :tada:

So what was the problem exactly? Do you have a typo? :thinking:

It’s just for the documentation if someone else has the same issue as you had. :memo:

1 Like

Yes, you’re right.

I suppose that I didn’t wait enough for the upload of one of the modified files.
Either ‘assets/core/css/custom-pdf.css’ or my proper invoice template file.

And I didn’t took notes of my way to edit the files.

2 Likes