Xls
in package
This class provides functions for creating and sending XLS files for download.
Tags
Table of Contents
Methods
cell()
Returns the th or td cell.
public
static cell(string $type, array<string|int, mixed> $item) : string
Parameters
- $type : string
-
The type of cell (th or td).
- $item : array<string|int, mixed>
-
The cell item.
Return values
string —The formatted cell HTML.
send()
Sends the XLS file for download.
public
static send(string $file, array<string|int, mixed> $header, array<string|int, mixed> $datas) : bool
Parameters
- $file : string
-
The file name without extension.
- $header : array<string|int, mixed>
-
The header section of the data.
- $datas : array<string|int, mixed>
-
The data.
Return values
bool —Returns true on success.