Jump to content

PDF logo size


Recommended Posts

I wanted to change logo for PDF invoice. I did it, but there's problem about the size. My logo size is bigger than it is supposed to be for invoice. What can I do? How can I allow my logo to be bigger? Any suggestions?

Thanx!

Link to comment
Share on other sites

You need to change line 139 of classes/PDF.php:

$this->Image(_PS_IMG_DIR_.'/logo.jpg', 10, 8, 0, 15);



The parameters after the image URL after for position x and y, then the image width and height. By default, the logo is placed 10 units from the left of the page and 8 units from the top of the page. It also has the height of the image set to 15 units and the width to 0, which means that the width is automatically calculated based on the height of the image. You can increase or decrease the 15 to adjust the size of the image.

Link to comment
Share on other sites

  • 1 year later...

I just tried changing 15 to 35 on my website using Dreamweaver CS5 and it worked fine. I'm not getting any error messages. Maybe you can try Wordpad instead of Notepad? There's nothing more I can do to help.

Link to comment
Share on other sites

Ah, thats worked! Lol!
Now i have another slight problem.
If i increase it to 35 for instance...i need to make the Delivery and Invoice address blocks down as it overlaps with the larger logo.

So in effect i need to push the whole page down.
Thanks

Link to comment
Share on other sites

You'll need to adjust the height of a cell to move everything down. Maybe increasing all the 10s in the if statements below the logo line will work. I suggest reading the tutorial and manual on the FPDF website for how to edit the PDF format.

Link to comment
Share on other sites

  • 2 years later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...