Skip to content
Parse and retrieve data from old format Excel XLS files. MS Excel 97 workbooks PHP reader.
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
examples Update 01-basic_usage.php Jun 17, 2019
src Date detection fixed Feb 19, 2019
.gitattributes Initial commit Nov 14, 2018
LICENSE Initial commit Nov 14, 2018
README.md Added Patreon badge Jun 1, 2019
composer.json Date detection fixed Feb 19, 2019
license.md Initial commit Nov 14, 2018

README.md

SimpleXLS class 0.9.4

Parse and retrieve data from old Excel XLS files. MS Excel 97 workbooks PHP reader. PHP BIFF reader. No addiditional extensions need (internal olereader). XLS only, MS Excel 2003+ php reader here

Sergey Shuchkin sergey.shuchkin@gmail.com 2016-2018

Basic Usage

if ( $xls = SimpleXLS::parse('book.xls') ) {
	print_r( $xls->rows() );
} else {
	echo SimpleXLS::parseError();
}
Array
(
    [0] => Array
        (
            [0] => ISBN
            [1] => title
            [2] => author
            [3] => publisher
            [4] => ctry
        )

    [1] => Array
        (
            [0] => 618260307
            [1] => The Hobbit
            [2] => J. R. R. Tolkien
            [3] => Houghton Mifflin
            [4] => USA
        )

)

Installation

composer require shuchkin/simplexls

Debug

ini_set('error_reporting', E_ALL );
ini_set('display_errors', 1 );

$xls = SimpleXLSX::parse('books.xlsx', false, true );
print_r( $xls->rows() );
print_r( $xls->sheets );

Classic OOP style

$xls = new SimpleXLS('books.xls');
if ($xls->success()) {
	print_r( $xls->rows() );
} else {
	echo 'xls error: '.$xls->error();
}

History

0.9.4 (2019-03-14) Added git Tag for prevent composer warning 
0.9.3 (2019-02-19) Fixed datetime detection
0.9.2 (2018-11-15) GitHub realese, composer
You can’t perform that action at this time.