Skip to content
Related Articles
Open in App
Not now

Related Articles

PHP | Spreadsheet_Excel_Writer | Introduction

Improve Article
Save Article
  • Difficulty Level : Easy
  • Last Updated : 29 Nov, 2019
Improve Article
Save Article

Introduction: Spreadsheet_Excel_Writer is a library written in PHP which helps to read from and write to different types of spreadsheet file formats with the help of given set of classes.


  • Easy and effective comparisons.
  • Powerful analysis of large amounts of data.
  • Splitting out large (or not so large) amounts of information in the form of a spreadsheet, which is easy to manipulate with a fairly ubiquitous spreadsheet program such as Excel (or OpenOffice).

Installation (Composer):

composer require pear/spreadsheet_excel_writer


// require_once 'Spreadsheet/Excel/Writer.php';
// Creating a workbook
$workbook = new Spreadsheet_Excel_Writer();
// Sending HTTP headers
// Creating a worksheet
$worksheet =& $workbook->addWorksheet('1st Worksheet');
// The actual data
$worksheet->write(0, 0, 'Website');
$worksheet->write(0, 1, 'Address');
$worksheet->write(1, 0, 'GeeksforGeeks');
$worksheet->write(1, 1, '');
// Let's send the file



My Personal Notes arrow_drop_up
Related Articles

Start Your Coding Journey Now!