For the complete documentation index, see llms.txt. This page is also available as Markdown.

Skip leading rows

  • Reading is available on Windows from extension 1.3.4.1 upwards;

  • Extension version >= 1.2.7;

  • When installing via PECL, answer yes when prompted to enable the reader.

Function Prototype

setSkipRows(int $skipRows): self

Discards the first $skipRows rows of the active sheet from the iterator. Apply it after openSheet() and before nextRow() / getSheetData().

Test data preparation

$config = ['path' => './tests'];
$excel  = new \Vtiful\Kernel\Excel($config);

$filePath = $excel->fileName('tutorial.xlsx')
    ->header(['', 'Cost'])
    ->data([
        [],
        ['viest', '']
    ])
    ->output();

Example 1

Example 2

Last updated