Terra Posted June 11, 2011 Share Posted June 11, 2011 The PDF Invoice uses the customers' address as guideline as to how many lines of text are shown. As result, if the company address is longer than the customer address, it is cut off. We use 7 lines in our address & have done this simple solution: In your template folder, find the file invoicepdf.tpl. Find the code: if ($customfields) { foreach ($customfields AS $customfield) { $pdf->Cell(88,4,$customfield['fieldname'].': '.$customfield['value'],'LR'); $pdf->Cell(4,4,''); $pdf->Cell(88,4,$companyaddress[$ci],'LR');$ci++; $pdf->Ln(); } } And below add: // We need to ensure that our address shows in full (we use 7 lines) while ($ci < 7) { $pdf->Cell(88,4,'','LR'); $pdf->Cell(4,4,''); $pdf->Cell(88,4,$companyaddress[$ci],'LR');$ci++; $pdf->Ln(); } NB: Please note that you need to change the number of lines to the ones you use. The company address is set in your WHMCS admin under "Set UP -> General Settings -> "Pay To Text". Edith 0 Quote Link to comment Share on other sites More sharing options...
WHMCS CEO Matt Posted June 13, 2011 WHMCS CEO Share Posted June 13, 2011 This is a tricky one as there's a lot of variation in what people put in that field, but addresses longer than 5 or 6 lines are unusual so for the current default templates we took the decision to support up to 5 lines by default. We'll look into if there's a better way of handling this with a multi-line cell maybe. Matt 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.