Laravel-excel: how to set align (left, ...) on cell or column...?

Created on 18 May 2014  ·  3Comments  ·  Source: Maatwebsite/Laravel-Excel

I want to set align in cell, column ... (not in view)?

Most helpful comment

$sheet->getStyle('A1')->getAlignment()->applyFromArray(
    array('horizontal' => 'center')
);

Shortcut will probably come in v1.1.0

All 3 comments

$sheet->getStyle('A1')->getAlignment()->applyFromArray(
    array('horizontal' => 'center')
);

Shortcut will probably come in v1.1.0

works for me, thanks.

Was this page helpful?
0 / 5 - 0 ratings