I want to chnage the text colour for just the text "HACCP Bulker Check" in the below code:
$pdf->SetTextColor(255,0,0);
$pdf->MultiCell($cell_width * 2, $cell_height, "HACCP Bulker Check
Pre-loading foreign object free", 'TLR', 1);
$pdf->SetTextColor(0,0,0);
Is there a way to do this? The rest of the text needs to be black.
How about splitting the text?
$pdf->SetTextColor(255,0,0);
$pdf->MultiCell($cell_width * 2, $cell_height, "HACCP Bulker Check", 'TLR', 1);
$pdf->Ln();
$pdf->SetTextColor(0,0,0);
$pdf->MultiCell($cell_width * 2, $cell_heigt, "Pre-loading foreign object free", 'LR', 1);
You might need to adjust the cell widths. Note the changed border value for the second cell.