Jump to content

PDF Header Image


troykelly

Recommended Posts

Apologies if this is already covered, but I have searched the manual and these forums and can not find a solution.

 

I am trying to see where I can set the header image displayed on the PDF's - at the moment it is the WHM logo.

 

Also, is it possible to edit / add content to the footer?

Link to comment
Share on other sites

Ok, I answered the first part of my own question searching the manual properly...

 

Modifying the Logo

 

The logo displayed on the PDF invoices is located in the images folder. To change this to your own logo simply upload your logo to the images folder and name it "logo.jpg".

Link to comment
Share on other sites

  • 1 month later...

The file: includes/pdfconfig.php

 

has this in it:

 

//Logo

$pdf->Image(dirname(__FILE__).'/../images/logo.jpg',140,8,50);

 

This does not set the dimensions of the image... I need to be able to change the width and height of the image, as it seems to be fixed to the size of the WHM logo.

 

Ther other two places where I am now using this logo, in the email templates and the printable invoice, the image is fine, but I can not find how to rescale the one in the pdf.

 

I did try changing the numbers in the line above, but they simply changed the location of the image, not it's size.

 

hope someone can help.

Link to comment
Share on other sites

  • 1 month later...

I had this problem too, so I looked around to find what pdf creation class was being used, and I'm pretty sure it's FPDF.

There's a handy reference manual at their site (fpdf.org/en/doc/index.php)

 

Specifically the Image page (fpdf.org/en/doc/image.htm), which shows that the 4th argument (the number 50 in your code) is the width, and there's an optional 5th argument for height.

If height isn't set, it's worked out automatically (and vice-versa).

Link to comment
Share on other sites

  • 4 months later...
yes, you can change everything in the pdf. i also changed "unpaid" to "we will process this invoice on the due date".

 

Hey generic or anyone else,

 

I can't seem to find where to change the text for the "Unpaid" put on the invoice.

I tried in the Language folder english.txt and that only changed it within the client area on and not on the actual pdf invoice.

 

On the "pdfconfig.php" I see "Which is “$pdf->Write(5,strtoupper($status));”", but don't know how to edit this file to have the invoice say "Open" instead of "Unpaid".

 

Any assistance here would be appreciated!

 

Paul

Link to comment
Share on other sites

  • 2 weeks later...
I had this problem too, so I looked around to find what pdf creation class was being used, and I'm pretty sure it's FPDF.

There's a handy reference manual at their site (fpdf.org/en/doc/index.php)

 

Specifically the Image page (fpdf.org/en/doc/image.htm), which shows that the 4th argument (the number 50 in your code) is the width, and there's an optional 5th argument for height.

If height isn't set, it's worked out automatically (and vice-versa).

 

That "50" in the code is actually the height and since there is no width set it will simply proportion your logo down to 50 pixels high and whatever the proportionate width would be.

 

Here's what I did to get my logo to render at the correct size:

 

Simply change the "50" to whatever the height of your logo is. Worked good for me anyway.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated