Hi everyone,
I found a class online that allows you to convert an array to a PDF document, formating them for AVERY label. I got it working and have formatted them to fit with the 3170 template.
My issue is I would like to style the information that is being echoed in the pdf document. Currently it just takes the two lines of data and places them to the top/left.
I would like to Center the text text-align:center; and make one line of text larger.
Anyone know how to do this?
The info is being generated to the pdf labels via the sprintf() function:
$pdf = new PDF_Label('5160', 'in', 1, 2);
$pdf->Open();
$pdf->AddPage();
$sql = mysql_query("SELECT firmTitle, attendee FROM attendees") or die(mysql_error());
while ($row = mysql_fetch_array($sql)) {
// Print labels
$pdf->Add_PDF_Label(sprintf("%s\n%s\n", ucwords($row['attendee']), $row['firmTitle']));
}
$pdf->Output();
Any advice? I know this is a tough one, but I am hoping someone may know.
SC