Marin Posted June 14, 2013 Share Posted June 14, 2013 I have a problem getting clear & crisp logo in the header of the PDF invoice file. Whatever I tried to change (size, format, dpi) the logo comes out blurred and completely unprofessional. I couldn't find any BEST PRACTICE tips for custom logo implementation so PLEASE give us some hints about how to get the fine looking logo in our PDF invoices. Thank you and regads. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted June 14, 2013 Share Posted June 14, 2013 if you've changed the size of the logo, did you also remember to change the size specified in the invoicepdf.tpl file ? http://docs.whmcs.com/PDF_Invoice 0 Quote Link to comment Share on other sites More sharing options...
Marin Posted June 14, 2013 Author Share Posted June 14, 2013 Let's say I don't want to change the size, I just want to know what is the default one and what is the BEST size and format (.png 8/24/32bit, .jpeg, .gif) to use by default. 0 Quote Link to comment Share on other sites More sharing options...
brian! Posted June 14, 2013 Share Posted June 14, 2013 the default pdf logo is called 'placeholder.png', it's 300px wide by 100px in height and is 24-bit - it's located in your 'images' directory inside WHMCS. I wouldn't have thought there is a "best" size, that should really be determined by your business logo - so long as the actual size (width especially) matches the width specified in invoicepdf.tpl, it should look fine. if your logo looks ok when viewed outside of the pdf, then it should look fine in the pdf (assuming dimensions match the tpl settings). if it helps, when I created our invoice pdf logo, I just opened the placeholder.png in photoshop and didn't resize it at all - I added our existing logo as a transparent layer, removed the original layer, saved it as logo.png and uploaded to the server... just checked the logo and I saved it at 32-bit (though don't recall why!). I would have thought that .png was the best format to use, but without seeing the logo, it's hard to say for certain. 0 Quote Link to comment Share on other sites More sharing options...
And then there was one les Posted June 16, 2013 Share Posted June 16, 2013 the size is important, well actually its not the size but the aspect ratio. You can make a larger logo if you want to very easily. Just grab the image brian mentioned and increase the size of it with the chain closed to keep the aspect ratio (photoshop, gimp etc). clear out the image and do your logo stuff. That way if whmcs resizes it you have already make it larger than it needs to be and the aspect ratio being correct should allow it to down size gracefully. i cant say as the clarity will be as good, that depends on how much resizing and the clarity of the original. 0 Quote Link to comment Share on other sites More sharing options...
berndkusen Posted May 14, 2014 Share Posted May 14, 2014 You can change the logo scaling factor at line 4 in invoicepdf.tpl in case of <code> if (file_exists(ROOTDIR.'/images/logo.png')) $pdf->Image(ROOTDIR.'/images/logo.png',20,25,75);</code> 75 is the scaling factor. 0 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.