PhpsPreadsheet setCellValue Finte de fondo de fila
$spreadsheet = new Spreadsheet();
$spreadsheet->getActiveSheet()->getStyle('A1:F1')->applyFromArray([
'fill' => [
'fillType' => Fill::FILL_SOLID,
'startColor' => [
'rgb' => 'FFDBE2F1',
]
],
]);
Or for single row//
$spreadsheet = new Spreadsheet();
$sheet = $spreadsheet->getActiveSheet();
{ inside Loop
$sheet->setCellValue('A1', 'ID');
$sheet->setCellValue('B1', 'Data di caricamento');
$sheet->setCellValue('C1', 'Via');
$sheet->setCellValue('D1', 'Municipio
$sheet->getStyle("A$cellIndex:I$cellIndex")->getFill()->setFillType(\PhpOffice\PhpSpreadsheet\Style\Fill::FILL_SOLID)->getStartColor()->setARGB($color);
}// end loop here
Singh99