Download the PHP package yidas/phpspreadsheet-helper without Composer

On this page you can find all versions of the php package yidas/phpspreadsheet-helper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package phpspreadsheet-helper

PHPSpreadsheet Helper

PHP Excel Helper - Write and read Spreadsheet with easy way based on PhpSpreadsheet

Latest Stable Version License Total Downloads Monthly Downloads

This library is a helper that encapsulate PhpSpreadsheet (Documentation) for simple usage.


OUTLINE


DEMONSTRATION

Write to Excel

Output an Excel file to browser for download:

Read from Excel

Import above excel file and return two-dimensional array data contained rows > columns spread sheet:

Output result:


REQUIREMENTS

This library requires the following:


INSTALLATION

Run Composer in your project:

composer require yidas/phpspreadsheet-helper

Then you could call it after Composer is loaded depended on your PHP framework:


USAGE

Import & Export

Simpliy read an Excel file then output to browser:

newSpreadsheet()

New or load an PhpSpreadsheet object

output()

Output file to browser

$format list: Xlsx, Xls, Html, Csv, Ods

save()

Save as file

Example:

Get Rows

getRow()

Get data of a row from the actived sheet of PhpSpreadsheet

Example:

Example of fetching content per each row (Example Code):

getRows()

Get rows from the actived sheet of PhpSpreadsheet

Example of getRows()

Add Rows

addRow()

Add a row to the actived sheet of PhpSpreadsheet

$rowData value: An array contains string or array of attributes for each cell
$rowAttributes value: string or array of attributes for each cell of a row

Example of addRow()

Example of setting attributes for each cell:

Example of setting attributes for each row:

addRows()

Add rows to the actived sheet of PhpSpreadsheet

$data value: array of each $rowData from addRow()
$rowAttributes value: string or array of attributes for each row

Example of addRows()

Attributes

Attributes is a standard array for defining a cell or even a row, the keys are as follows:

key, value, style

PhpSpreadsheet Original Usage Integration

This helper is flexible that you could inject or extract original PhpSpreadsheet with it, when you need to manipulate some Phpspreadsheet methods integrated with Helper.

Inject PhpSpreadsheet

Extract PhpSpreadsheet

Merge Cells

It's easy to merge cells by defining each cell's span attributes:

Multiple Sheets

setSheet()

Set an active PhpSpreadsheet Sheet

getSheet()

Get PhpSpreadsheet Sheet object from cache

Example:

Map of Coordinates & Ranges

The result could be:

Style Attributes

The style attribute could be set on a range of cells.

Style array key/value/constant refers Valid array keys for style applyFromArray() or Source Classes

Columns Format

The options for each cell data:

All Cells Format

This section focuses on applying all actived cells or ranged cells on the sheet, not just effecting single cell, row or column.

setStyle()

Set Style for all actived cells or set by giving range to the actived sheet

Example:

setWrapText()

Set WrapText for all actived cells or set by giving range to the actived sheet

setAutoSize()

Set AutoSize for all actived cells or set by giving column range to the actived sheet


LIMITATIONS

Performance Issue

If you're building large cell data with XLSX, you may face performance issue with memory usage and execution time.

box/spout spreadsheet lirary supports building Excel file with high performance, you could use this library instead if you do not need more style and formatting requirements.


All versions of phpspreadsheet-helper with dependencies

PHP Build Version
Package Version
Requires phpoffice/phpspreadsheet Version ^1.1.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package yidas/phpspreadsheet-helper contains the following files

Loading the files please wait ....