All Projects → Slamdunk → php-excel

Slamdunk / php-excel

Licence: MIT license
Old faster PHPExcel

Programming Languages

PHP
23972 projects - #3 most used programming language
Makefile
30231 projects

Projects that are alternatives of or similar to php-excel

excel mysql
Module for import Excel files to MySQL table and export MySQL table to Excel file using PHPExcel
Stars: ✭ 30 (+20%)
Mutual labels:  excel, phpexcel
excel-merge
A PHP library to merge two or more Excel files into one
Stars: ✭ 26 (+4%)
Mutual labels:  excel, phpexcel
Phpspreadsheet
A pure PHP library for reading and writing spreadsheet files
Stars: ✭ 10,627 (+42408%)
Mutual labels:  excel, phpexcel
Seatable
SeaTable: easy like a spreadsheet, powerful like a database
Stars: ✭ 231 (+824%)
Mutual labels:  excel
Relaxtools Addin
RelaxTools Addin for Microsoft Excel 2010/2013/2016
Stars: ✭ 234 (+836%)
Mutual labels:  excel
Handsontable
JavaScript data grid with a spreadsheet look & feel. Works with React, Angular, and Vue. Supported by the Handsontable team ⚡
Stars: ✭ 16,059 (+64136%)
Mutual labels:  excel
fmtdate
MS Excel (TM) syntax for Go time/date
Stars: ✭ 95 (+280%)
Mutual labels:  excel
Django Data Wizard
🧙⚙️ Import structured data (e.g. Excel, CSV, XML, JSON) into one or more Django models via an interactive web-based wizard
Stars: ✭ 227 (+808%)
Mutual labels:  excel
wxAutoExcel
wxAutoExcel is a wxWidgets library attempting to make Microsoft Excel automation with C++ a bit less painful.
Stars: ✭ 27 (+8%)
Mutual labels:  excel
Vscode Data Preview
Data Preview 🈸 extension for importing 📤 viewing 🔎 slicing 🔪 dicing 🎲 charting 📊 & exporting 📥 large JSON array/config, YAML, Apache Arrow, Avro, Parquet & Excel data files
Stars: ✭ 245 (+880%)
Mutual labels:  excel
Zipcelx
Turns JSON data into `.xlsx` files in the browser
Stars: ✭ 246 (+884%)
Mutual labels:  excel
Kkfileviewofficeedit
文件在线预览及OFFICE(word,excel,ppt)的在线编辑
Stars: ✭ 234 (+836%)
Mutual labels:  excel
vue-datagrid
Spreadsheet data grid component. Handles enormous data processing.
Stars: ✭ 171 (+584%)
Mutual labels:  excel
Psexcel
A simple Excel PowerShell module
Stars: ✭ 234 (+836%)
Mutual labels:  excel
react-datasheet-grid
An Airtable-like / Excel-like component to create beautiful spreadsheets.
Stars: ✭ 227 (+808%)
Mutual labels:  excel
Closedxml.report
ClosedXML.Report is a tool for report generation with which you can easily export any data from your .NET classes to Excel using a XLSX-template.
Stars: ✭ 230 (+820%)
Mutual labels:  excel
xlstream
Turns XLSX into a readable stream.
Stars: ✭ 148 (+492%)
Mutual labels:  excel
Easyexcel Encapsulation
easyexcel 的方法封装,快速、简单地处理 Excel
Stars: ✭ 243 (+872%)
Mutual labels:  excel
Layui Excel
简单快捷的导出插件,导出仅需一句话
Stars: ✭ 239 (+856%)
Mutual labels:  excel
Styleframe
A library that wraps pandas and openpyxl and allows easy styling of dataframes in excel
Stars: ✭ 252 (+908%)
Mutual labels:  excel

ABANDONED, use slam/openspout-helper

Slam PHPExcel old&faster

Latest Stable Version Downloads Integrate Code Coverage

This package is NOT intended to be complete and flexible, but to be fast.

PHPOffice/PHPExcel and PHPOffice/PhpSpreadsheet are great libraries, but abstract everything in memory before writing to the disk. This is extremely inefficent and slow if you need to write a giant XLS with thousands rows and hundreds columns.

Based on Spreadsheet_Excel_Writer v0.9.3, which can be found active on Github. This is not a fork: I copied it and adapted to work with PHP 7.1 and applied some coding standard fixes and some Scrutinizer patches.

Installation

composer require slam/php-excel

Usage

From version 4 the code is split in two parts:

  1. Slam\Excel\Pear namespace, the original Pear code
  2. Slam\Excel\Helper namespace, an helper to apply a trivial style on a Table structure:
use Slam\Excel\Helper as ExcelHelper;

require __DIR__ . '/vendor/autoload.php';

// Being an Iterator, the data can be any dinamically generated content
// for example a PDOStatement set on unbuffered query
$users = new ArrayIterator([
    [
        'column_1' => 'John',
        'column_2' => '123.45',
        'column_3' => '2017-05-08',
    ],
    [
        'column_1' => 'Mary',
        'column_2' => '4321.09',
        'column_3' => '2018-05-08',
    ],
]);

$columnCollection = new ExcelHelper\ColumnCollection([
    new ExcelHelper\Column('column_1',  'User',     10,     new ExcelHelper\CellStyle\Text()),
    new ExcelHelper\Column('column_2',  'Amount',   15,     new ExcelHelper\CellStyle\Amount()),
    new ExcelHelper\Column('column_3',  'Date',     15,     new ExcelHelper\CellStyle\Date()),
]);

$filename = sprintf('%s/my_excel_%s.xls', __DIR__, uniqid());

$phpExcel = new ExcelHelper\TableWorkbook($filename);
$worksheet = $phpExcel->addWorksheet('My Users');

$table = new ExcelHelper\Table($worksheet, 0, 0, 'My Heading', $users);
$table->setColumnCollection($columnCollection);

$phpExcel->writeTable($table);
$phpExcel->close();

Result:

Example

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].